Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Annotate captcha assessments #1043
Annotate captcha assessments #1043
Changes from 2 commits
a936530
3ef1fe0
94e1342
3e1681d
24f3dc8
c4fb455
d0e0d02
80ccd44
a8b3ca6
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
Check warning on line 780 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L779-L780
Check warning on line 782 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L782
Check warning on line 789 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L785-L789
Check warning on line 791 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L791
Check warning on line 795 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L793-L795
Check warning on line 801 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L798-L801
Check warning on line 805 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L804-L805
Check warning on line 807 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L807
Check warning on line 809 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L809
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.
The function name is a bit misleading, isn't it? It doesn't determine if it should be annotated or not but rather always returns a new/expected assessment annotation, right?
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 was using
ANNOTATION_UNSPECIFIED
as the base case where we don't actually do the annotation. In the other function we check whether it'sANNOTATION_UNSPECIFIED
and if so we skip annotating the assessment. But I'm fine to change it if it's confusing. Do you have a suggestion to make it more clear?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 renamed the function to
getCaptchaAssessmentAnnotation
, let me know if you think another name would be betterCheck warning on line 817 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L815-L817
Check warning on line 819 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L819
Check warning on line 823 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L822-L823
Check warning on line 826 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L825-L826
Check warning on line 828 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L828
Check warning on line 830 in controllers/usersignup/usersignup_controller.go
Codecov / codecov/patch
controllers/usersignup/usersignup_controller.go#L830