Skip to content

Commit

Permalink
chore: should use xx.String() instead of string(xx.Bytes()) (#725)
Browse files Browse the repository at this point in the history
  • Loading branch information
testwill committed Jun 28, 2023
1 parent be633f7 commit d3f8f8a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions autorest/authorization_storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ func buildCanonicalizedResource(accountName, uri string, keyType SharedKeyType)
}
}

return string(cr.Bytes()), nil
return cr.String(), nil
}

func getCanonicalizedAccountName(accountName string) string {
Expand Down Expand Up @@ -289,7 +289,7 @@ func buildCanonicalizedHeader(headers http.Header) string {
ch.WriteRune('\n')
}

return strings.TrimSuffix(string(ch.Bytes()), "\n")
return strings.TrimSuffix(ch.String(), "\n")
}

func createAuthorizationHeader(accountName string, accountKey []byte, canonicalizedString string, keyType SharedKeyType) string {
Expand Down

0 comments on commit d3f8f8a

Please sign in to comment.