Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Category with services - 'enabled' unexpected behaviour #648

Closed
frankykubo opened this issue Feb 26, 2024 · 0 comments
Closed

[Bug]: Category with services - 'enabled' unexpected behaviour #648

frankykubo opened this issue Feb 26, 2024 · 0 comments
Labels
bug:confirmed bug Something isn't working triage yet to be reviewed
Milestone

Comments

@frankykubo
Copy link

Expected Behavior

When I do not consent right away but open the setting modal instead, by default the category and all the services under it should be enabled. Thats happening.

When I click Save preferences, then, in onConsent function parameter (cookie), I get services object where there are by-config-enabled services included.

Current Behavior

When I click Save preferences in Settings modal before first consent, then, in onConsent function parameter (cookie), I get services object where there are NOT by-config-enabled services included.

Also, CookieConsent.acceptedService('test', 'analytics') is false, which should be true.

Steps to reproduce

Reproduced here, by setting updating analytics category:

analytics: {
      services: {
        test: {
          label: 'Test',
        },
      },
      enabled: true,
    },
  1. Click Manage preferences in UI
  2. Click Save preferences in UI
  3. See console, where parameter of onConsent is logged
  4. Look for services object, where under analytics, test should be included, but it is not.

Proposed fix or additional info.

No response

Version

3.0.0

On which browser do you see the issue?

No response

@frankykubo frankykubo added the bug Something isn't working label Feb 26, 2024
@github-actions github-actions bot added the triage yet to be reviewed label Feb 26, 2024
@orestbida orestbida added bug:confirmed and removed triage yet to be reviewed labels Mar 3, 2024
@orestbida orestbida added this to the v3.1.0 milestone Mar 3, 2024
@orestbida orestbida reopened this Apr 1, 2024
@github-actions github-actions bot added the triage yet to be reviewed label Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug:confirmed bug Something isn't working triage yet to be reviewed
Projects
None yet
Development

No branches or pull requests

2 participants