From ffe496391ed92901b5547b5fa8c0f06b41d75935 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Machulda?= Date: Mon, 17 Jan 2022 14:56:23 +0100 Subject: [PATCH] Feat: Submit consent to API also on settings change #CCM-59 --- src/LmcCookieConsentManager.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/LmcCookieConsentManager.ts b/src/LmcCookieConsentManager.ts index f3cb6caa..3a918345 100644 --- a/src/LmcCookieConsentManager.ts +++ b/src/LmcCookieConsentManager.ts @@ -143,6 +143,9 @@ const LmcCookieConsentManager: CookieConsentManager = (serviceName, args) => { ? onFirstAcceptOnlyNecessary(cookie, cookieConsent) : onFirstAcceptAll(cookie, cookieConsent); }, + onChange: () => { + submitConsent(consentCollectorApiUrl, cookieConsent); + }, languages, // override default config if necessary ...config,