Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Explicit setting of integrations prevents sending of user_hash. #10

Open
more-ron opened this issue Mar 1, 2016 · 3 comments
Open

Explicit setting of integrations prevents sending of user_hash. #10

more-ron opened this issue Mar 1, 2016 · 3 comments
Labels
migrated The issue has been migrated

Comments

@more-ron
Copy link

more-ron commented Mar 1, 2016

We a have a code that dynamically turns on or off Intercom integration depending on the user.

We hit a condition when it should send it to Intercom but it doesn't. It does try to send it but it's missing the user_hash.

        analytics.identify('id', { ... }, {
          Intercom: { user_hash: 'x' },
          integrations: {
            All: true,
            ...,
            Intercom: true
          }
        });

Removing the explicit setting fixed it.

        analytics.identify('id', { ... }, {
          Intercom: { user_hash: 'x' },
          integrations: {
            All: true,
            ...
          }
        });

However that just a work around and it makes the backend code a bit more complicated now that it has to decide to include the Intercom key rather than just setting the value to either true or false.

It's also setting a trap for developers expecting it to just work.

@hankim813
Copy link
Contributor

Hey @more-ron thanks so much for bringing this up. This is definitely a known issue and is a problem that is rooted at our analytics.js library. Basically, the library does not let you use selective integrations AND integration specific options such as the user_hash.

We've added a note internally to address this issue at the platform level.

@armordog
Copy link

This is a big deal for me.

I'm using Intercom's secure mode so I have to send the user_hash.
I can explicitly disable Intercom with integrations: { Intercom:false }
But sending integrations: { All: true } doesn't turn it back on.

Is there a workaround aside from forcing a browser refresh?

@SegmentDestinationsBot
Copy link

Hi @more-ron, as part of the monorepo migration, this issue has been moved to new issue. Our engineers have been notified and will prioritize and work on it ASAP. Thank you!

For more information, see README.md.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
migrated The issue has been migrated
Projects
None yet
Development

No branches or pull requests

4 participants