Browse Source

Fix delete SSH key in file

pull/31/head
Unknown 11 years ago
parent
commit
c83657307e
  1. 2
      models/publickey.go

2
models/publickey.go

@ -134,7 +134,7 @@ func DeletePublicKey(key *PublicKey) (err error) {
} }
// Found the line and copy rest of file. // Found the line and copy rest of file.
if strings.Contains(line, key.Content) { if strings.Contains(line, fmt.Sprintf("key-%d", key.Id)) && strings.Contains(line, key.Content) {
continue continue
} }
// Still finding the line, copy the line that currently read. // Still finding the line, copy the line that currently read.

Loading…
Cancel
Save