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

Enable Secure Mode #26

Closed
wants to merge 2 commits into from

Conversation

mbbertino
Copy link

This should address #15, allowing optional enabling of secure mode.

@mbbertino mbbertino mentioned this pull request Jun 15, 2016
@seawatts
Copy link

I think this can be achieved by using #30

@mbbertino
Copy link
Author

mbbertino commented Jun 21, 2016

@seawatts Hey that looks awesome! But I'm actually having problems with sending custom data through with that most recent 0.1.1 which I think has your branch merged in.

This is what I'm doing, what am I missing?

setUserInIntercom(user) {
  let props = {
    'user.name': `User ${user.get('name')}`,
    'user.user_id': user.get('id'),
    'user.email': user.get('email'),
    'user.createdAt': user.get('createdAt'),
    'user.userHash': user.get('intercomUserHash')
  }

  this.get('intercom').setProperties(props)
},

@seawatts
Copy link

You have to call this.get('intercom').update(props) or this.get('intercom').start(props)

@mbbertino
Copy link
Author

@seawatts Ah, thanks for that I'll try that soon and confirm it solves it ,then I'll close the issue and pr.

@mbbertino
Copy link
Author

Alright @seawatts that seems to be working! The only change I had to make to make it work was the way I was creating props. It didn't respect the prop keys if they were "user.KEYNAME".

setUserInIntercom(user) {
  let intercom = this.get('intercom'),
      props = {
        name: user.get('name'),
        user_id: user.get('id'),
        email: user.get('email'),
        createdAt: user.get('createdAt'),
        userHash: user.get('intercomUserHash')
      }

  intercom.start(props)
},

@mbbertino mbbertino closed this Jun 22, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants