Skip to content

fix: update status code returned when max number of enrolled factors is exceeded - #1676

Closed
J0 wants to merge 1 commit into
masterfrom
j0/change_mfa_error_code
Closed

J0 wants to merge 1 commit into
masterfrom
j0/change_mfa_error_code

Conversation

@J0

@J0 J0 commented Jul 24, 2024 •

Copy link
Copy Markdown
Contributor

What kind of change does this PR introduce?

Return un-processable entity error instead of forbidden error when a user has exceeded the maximum allowable number of enrolled factors.

I am guessing that is unlikely that folks depend on the specific status code. Open to suggestions if there are concrete ways to confirm / disconfirm this though

Addresses: #1668 (comment)

@J0
J0 requested a review from a team as a code owner July 24, 2024 13:36
@J0 J0 mentioned this pull request Jul 24, 2024
@J0 J0 changed the title fix: update status code return when max number of enrolled factors is exceeded fix: update status code returned when max number of enrolled factors is exceeded Jul 24, 2024
@coveralls

Copy link
Copy Markdown

Pull Request Test Coverage Report for Build 10077740406

Details

  • 0 of 2 (0.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 57.995%

Changes Missing Coverage Covered Lines Changed/Added Lines %
internal/api/mfa.go 0 2 0.0%
Totals Coverage Status
Change from base Build 10035433302: 0.0%
Covered Lines: 8817
Relevant Lines: 15203

💛 - Coveralls

@kangmingtay kangmingtay left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

let's not do this as it is considered a breaking change

@hf

hf commented Jul 25, 2024

Copy link
Copy Markdown
Contributor

let's not do this as it is considered a breaking change

It's not a breaking change, as we explicitly tell people not to rely on the status code only the status code class.

@hf
hf dismissed kangmingtay’s stale review July 25, 2024 11:08

Not a breaking change, with previous precedent. Supabase Auth does not guarantee HTTP status code stability, only status code class.

@J0 J0 closed this Jul 25, 2024
@J0

J0 commented Jul 25, 2024

Copy link
Copy Markdown
Contributor Author

Closing for now as discussed

@J0
J0 deleted the j0/change_mfa_error_code branch November 21, 2024 08:09
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.

4 participants