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

fix: handle null as the first argument in identify #950

Merged
merged 3 commits into from
Oct 10, 2023
Merged

Conversation

oscb
Copy link
Contributor

@oscb oscb commented Sep 14, 2023

  • I've included a changeset (psst. run yarn changeset. Read about changesets here).

@changeset-bot
Copy link

changeset-bot bot commented Sep 14, 2023

🦋 Changeset detected

Latest commit: 121a317

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@segment/analytics-next Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

options?: Options
callback?: Callback
} = {}
// It's a stack so it's reversed so that we go through each of the expected arguments
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a leetcode problem 😁

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It totally is

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I f'ing love this.

@oscb oscb requested a review from silesky September 29, 2023 17:58
callback?: Callback
} = {}
// It's a stack so it's reversed so that we go through each of the expected arguments
const orderStack: Array<keyof typeof values> = [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Using the old TS array syntax???

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some reason eslint didn't like the new syntax :(

Copy link
Contributor

@silesky silesky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@oscb oscb closed this Oct 10, 2023
@oscb oscb reopened this Oct 10, 2023
@oscb oscb merged commit c0dadc7 into master Oct 10, 2023
5 checks passed
@oscb oscb deleted the oscb/traitsFix branch October 10, 2023 19:18
@github-actions github-actions bot mentioned this pull request Oct 10, 2023
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.

analytics.identify sends traits through context when userId is null (version 1.53.0)
4 participants