index
:
gogs.git
Gogs is a painless self-hosted Git service
log msg
author
committer
range
buildscript
main
mygogs
about
summary
refs
log
tree
commit
diff
path:
root
/
models
diff options
context:
1
2
3
4
5
6
7
8
9
10
15
20
25
30
35
40
space:
include
ignore
mode:
unified
ssdiff
stat only
Diffstat
(limited to 'models')
-rw-r--r--
models/publickey.go
2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/publickey.go b/models/publickey.go
index ad92d64f..6c0ffc0c 100644
--- a/
models/publickey.go
+++ b/
models/publickey.go
@@ -153,7 +153,7 @@ func parseKeyString(content string) (string, error) {
if len(lines) == 1 {
// Parse openssh format
- parts := strings.Fields(lines[0])
+ parts := strings.SplitN(lines[0], " ", 3)
switch len(parts) {
case 0:
return "", errors.New("Empty key")