Skip to content

fix: Wrong authentication property key for Segment event in app/core/SecureKeychain.js #8860

@NicolasMassart

Description

@NicolasMassart

What is this about?

Wrong authentication property key for Segment event in app/core/SecureKeychain.js discovered while doing QA:
The event props should look like:

    await MetaMetrics.getInstance().addTraitsToUser({
      [UserProfileProperty.AUTHENTICATION_TYPE]: AUTHENTICATION_TYPE.PASSWORD,
    });

instead of

    await MetaMetrics.getInstance().addTraitsToUser({
      [NATIVE_AUTH_TYPE]: AUTHENTICATION_TYPE.PASSWORD,
    });

Also, fix typo on UserProfilePropery to UserProfileProperty

Scenario

No response

Design

No response

Technical Details

In app/core/SecureKeychain.js, replace NATIVE_AUTH_TYPE by UserProfileProperty.AUTHENTICATION_TYPE

Threat Modeling Framework

No response

Acceptance Criteria

  • Auth events are sent with the correct auth property key in Segment:
    Traits should look like:
      "traits": {
        "$city": "",
        "$country_code": "FR",
        "$region": "NOR",
        "$timezone": "Europe/Paris",
        "Authentication Type": "password",
      },
    Instead of :
      "traits": {
        "$city": "",
        "$country_code": "FR",
        "$region": "NOR",
        "$timezone": "Europe/Paris",
        "[object Object]": "password"
      },
  • typo fixed

Stakeholder review needed before the work gets merged

  • Engineering (needed in most cases)
  • Design
  • Product
  • QA (automation tests are required to pass before merging PRs but not all changes are covered by automation tests - please review if QA is needed beyond automation tests)
  • Security
  • Legal
  • Marketing
  • Management (please specify)
  • Other (please specify)

References

No response

Metadata

Metadata

Labels

next releaserelease-7.18.0Issue or pull request that will be included in release 7.18.0release-7.19.0Issue or pull request that will be included in release 7.19.0release-blockerThis bug is blocking the next releaseteam-mobile-platformMobile Platform team

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions