-
Notifications
You must be signed in to change notification settings - Fork 83
Conversation
pkg/controller/issueapi/gen_code.go
Outdated
if errors.Is(err, database.ErrAlreadyReported) { | ||
return &IssueResult{ | ||
obsResult: enobs.ResultError("DUPLICATE_USER_REPORT"), | ||
HTTPCode: http.StatusTooManyRequests, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel like StatusTooManyRequests implies rate-limiting? Would conflict be more appropriate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
other ideas, just 400? 403?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
409 would be most appropriate. I think we need to document the response and explain what clients should do instead.
# Create secret for the database HMAC for phone numbers | ||
resource "random_id" "db-phone-number-hmac" { | ||
count = var.db_phone_number_hmac_count | ||
byte_length = 128 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some of the comments say 256?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is the HMAC secret length, not the nonce length
updated + added api docs. |
Test failures seem real? |
Towards #1928
Proposed Changes
New checkbox to enable user report
New SMS template for "User Report"
Release Note