Skip to content

Commit

Permalink
Feat: Submit consent to API and dataLayer also on settings change #CC…
Browse files Browse the repository at this point in the history
…M-59
  • Loading branch information
OndraM committed Feb 11, 2022
1 parent a417b8d commit 1daca26
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/LmcCookieConsentManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,12 @@ const LmcCookieConsentManager: CookieConsentManager = (serviceName, args) => {
changed: changedCategories,
};

pushToDataLayer(cookie);

if (consentCollectorApiUrl !== null) {
submitConsent(consentCollectorApiUrl, cookieConsent);
}

onChange(cookieConsent, categories);
};

Expand Down

0 comments on commit 1daca26

Please sign in to comment.