Skip to content
This repository was archived by the owner on Jun 25, 2025. It is now read-only.
This repository was archived by the owner on Jun 25, 2025. It is now read-only.

Identifying by email only works if each event sends email #26

Description

@tiina303

The problem:

  1. we make the decision to send the person or not based on if they have ever had email set
    return customer.status.has('with_email')
  2. however in the current event we might not have the email
    const email = getEmailFromEvent(event)
    (
    customerStatus.add('with_email')
    could have been set by a previous event)
  3. then we never override the id, because we didn't have an email
    id = customer.email

If I understand correctly, then we would always want to update the properties, i.e. send the identify when the person properties change

which would mean we'd need to instead of keeping the info that the person has been identified by email we'd need to keep the emails, which is a bit tricky (running arbitrary code, e.g. SQL injection that we'll need to guard against), in addition to increasing our storage demand.

We currently don't have a way to pass person info to the plugins, which would be the ideal solution for this problem

See thread for more info: https://posthog.slack.com/archives/C03PN99EJ4C/p1675946098284529

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions