优化
This commit is contained in:
parent
1cf6327385
commit
3291d5e5cc
|
@ -64,10 +64,7 @@ func (p *PasswordHash) getRandomBytes(count int) (r string, err error) {
|
||||||
func (p *PasswordHash) Encode64(input string, count int) (out string) {
|
func (p *PasswordHash) Encode64(input string, count int) (out string) {
|
||||||
i := 0
|
i := 0
|
||||||
s := strings.Builder{}
|
s := strings.Builder{}
|
||||||
for {
|
for i < count {
|
||||||
if i >= count {
|
|
||||||
break
|
|
||||||
}
|
|
||||||
v := 0
|
v := 0
|
||||||
if i < len(input) {
|
if i < len(input) {
|
||||||
v = int(input[i])
|
v = int(input[i])
|
||||||
|
|
Loading…
Reference in New Issue
Block a user