GDPR icon indicating copy to clipboard operation
GDPR copied to clipboard

Consents without page assigned shown as "ON" by default instead of "OFF"

Open tyrann0us opened this issue 7 years ago • 0 comments

Steps to reproduce

  1. Add consent without assigning a policy page to it
  2. Open website in incognito mode

Current behavior

The consent's switch is shown as "ON" but the gdpr[consent_types] cookie is just an empty object ([]) and has_consent() will return false for the given consent.

Expected behavior

The consent's switch should be shown as "OFF".

Notes

Workaround: Set an invalid consent in the gdpr[consent_types] cookie (e. g. ['foo']). This will cause the consent's switch to be shown as "OFF".

This is related to #202.

tyrann0us avatar Jun 22 '18 14:06 tyrann0us