Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
vietredweb committed Oct 10, 2024
1 parent 627613b commit db1eda0
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/Components/ConsentCustom.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -677,11 +677,6 @@ const ConsentComponentCustomApp = (props: any) => {
event_name: 'Revoke consent',
event_type: 'revoke-consent',
});
if (levelRevoke === '1' && window['aesirx1stparty']) {
setTimeout(() => {
window.location.reload();
}, 1000);
}
} catch (error) {
console.log(error);
setLoading('done');
Expand Down Expand Up @@ -938,6 +933,14 @@ const ConsentComponentCustomApp = (props: any) => {
onClick={async () => {
if (revokeConsentOption === 'consent') {
await handleRevokeBtn();
const levelRevoke =
sessionStorage.getItem('aesirx-analytics-revoke') &&
parseInt(sessionStorage.getItem('aesirx-analytics-revoke'));
if (levelRevoke > 1 || window['aesirx1stparty']) {
setTimeout(() => {
window.location.reload();
}, 1000);
}
} else {
sessionStorage.removeItem(revokeConsentOption);
setShowExpandRevoke(false);
Expand Down

0 comments on commit db1eda0

Please sign in to comment.