Skip to content

Improve randomString function#428

Merged
vilmibm merged 1 commit intocli:masterfrom
vertextau:oauth-fix
Feb 14, 2020
Merged

Improve randomString function#428
vilmibm merged 1 commit intocli:masterfrom
vertextau:oauth-fix

Conversation

@vertextau
Copy link
Copy Markdown
Contributor

Hi!
I noticed that you use Sprintf to return a hex string. But it is slower because it has to parse the format string first. This patch brings EncodeToString from encoding/hex package to improve randomString function.

Copy link
Copy Markdown
Contributor

@vilmibm vilmibm left a comment

Choose a reason for hiding this comment

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

neat, thanks!

@vilmibm vilmibm merged commit 10ea161 into cli:master Feb 14, 2020
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