Skip to content

fix(clerk-js,elements,types,ui): Account for null in supported_first_factors#3938

Merged
LekoArts merged 4 commits intomainfrom
ds.fix/supported-first-factor-null
Aug 13, 2024
Merged

fix(clerk-js,elements,types,ui): Account for null in supported_first_factors#3938
LekoArts merged 4 commits intomainfrom
ds.fix/supported-first-factor-null

Conversation

@dstaley
Copy link
Member

@dstaley dstaley commented Aug 12, 2024

Description

In certain situations (such as the email_link sign in flow), the API returns "supported_first_factors": null. Currently, our types expect this value to always be an array, which results in a runtime TypeError when we attempt to use any method on the value expecting an array.

Checklist

  • npm test runs as expected.
  • npm run build runs as expected.
  • (If applicable) JSDoc comments have been added or updated for any package exports
  • (If applicable) Documentation has been updated

Type of change

  • 🐛 Bug fix
  • 🌟 New feature
  • 🔨 Breaking change
  • 📖 Refactoring / dependency upgrade / documentation
  • other:

@changeset-bot
Copy link

changeset-bot bot commented Aug 12, 2024

🦋 Changeset detected

Latest commit: 19af466

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

This PR includes changesets to release 19 packages
Name Type
@clerk/clerk-js Patch
@clerk/elements Patch
@clerk/types Patch
@clerk/ui Patch
@clerk/astro Patch
@clerk/chrome-extension Patch
@clerk/clerk-expo Patch
@clerk/backend Patch
@clerk/express Patch
@clerk/fastify Patch
@clerk/localizations Patch
@clerk/nextjs Patch
@clerk/clerk-react Patch
@clerk/remix Patch
@clerk/clerk-sdk-node Patch
@clerk/shared Patch
@clerk/tanstack-start Patch
@clerk/testing Patch
@clerk/themes 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

@LekoArts LekoArts enabled auto-merge (squash) August 13, 2024 06:52
@LekoArts LekoArts disabled auto-merge August 13, 2024 06:53
@LekoArts LekoArts changed the title fix(clerk-js,elements,types,ui): Account for null supported_first_factors fix(clerk-js,elements,types,ui): Account for null in supported_first_factors Aug 13, 2024
@LekoArts LekoArts enabled auto-merge (squash) August 13, 2024 06:53
@LekoArts LekoArts merged commit b6f0613 into main Aug 13, 2024
@LekoArts LekoArts deleted the ds.fix/supported-first-factor-null branch August 13, 2024 07:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants