summaryrefslogtreecommitdiffstats
path: root/models/ssh_key.go
diff options
context:
space:
mode:
authorBo-Yi Wu <appleboy.tw@gmail.com>2017-01-27 23:03:32 +0800
committerLunny Xiao <xiaolunwen@gmail.com>2017-01-27 23:03:32 +0800
commit25663b58161c48bdc8e9cae900544378dede0d2b (patch)
tree1d0cab794b549116cf685101a62cc21634356d6b /models/ssh_key.go
parent4faf097fb9d07003b52d5f6e51ad3e624a5db062 (diff)
downloadgitea-25663b58161c48bdc8e9cae900544378dede0d2b.tar.gz
gitea-25663b58161c48bdc8e9cae900544378dede0d2b.zip
refactor: Remove unnecessary type conversions (#772)
Diffstat (limited to 'models/ssh_key.go')
-rw-r--r--models/ssh_key.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/ssh_key.go b/models/ssh_key.go
index 2f23026997..3bd2a739df 100644
--- a/models/ssh_key.go
+++ b/models/ssh_key.go
@@ -219,7 +219,7 @@ func SSHKeyGenParsePublicKey(key string) (string, int, error) {
func SSHNativeParsePublicKey(keyLine string) (string, int, error) {
fields := strings.Fields(keyLine)
if len(fields) < 2 {
- return "", 0, fmt.Errorf("not enough fields in public key line: %s", string(keyLine))
+ return "", 0, fmt.Errorf("not enough fields in public key line: %s", keyLine)
}
raw, err := base64.StdEncoding.DecodeString(fields[1])