segmentio / consent-manager

Drop-in consent management plugin for analytics.js
https://segmentio.github.io/consent-manager/
MIT License
340 stars 142 forks source link

Custom analytics events stopped working #341

Closed AndreiBil closed 1 year ago

AndreiBil commented 1 year ago

After implementing the consent manager, custom events stopped working, such as:

function identifyUserTracking(user) {
        analytics.identify(user.uuid, {
            firstName: user.first_name,
            lastName: user.last_name,
            username: user.display_name,
            phone: user.phone,
            reputation: user.reputation,
            email: user.email
        }, { context: { ip: "0.0.0.0" }});

    }

        function customEventTracking(eventName, points, subject) {

        analytics.track(eventName, {
            value: points,
            subject: subject,
        }, { context: { ip: "0.0.0.0" }});

    }
Did I miss something in the docs, cause I am not sure what is causing this?

Thanks