Skip to content

fix: change mask-secret function#251

Merged
evgeniy-scherbina merged 5 commits intomainfrom
yevhenii/mask-secret
Apr 10, 2026
Merged

fix: change mask-secret function#251
evgeniy-scherbina merged 5 commits intomainfrom
yevhenii/mask-secret

Conversation

@evgeniy-scherbina
Copy link
Copy Markdown
Contributor

@evgeniy-scherbina evgeniy-scherbina commented Apr 9, 2026

@evgeniy-scherbina evgeniy-scherbina marked this pull request as ready for review April 9, 2026 19:04
utils/mask.go Outdated
if reveal == 0 || reveal*2 >= len(runes) {
return "***"
if len(runes) <= reveal*2 {
return s
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

We should never reveal the input, under any circumstances.

Copy link
Copy Markdown
Collaborator

@dannykopping dannykopping left a comment

Choose a reason for hiding this comment

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

LGTM, thanks @evgeniy-scherbina!

@evgeniy-scherbina evgeniy-scherbina merged commit 9ac7525 into main Apr 10, 2026
4 checks passed
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.

2 participants