summaryrefslogtreecommitdiffstats
path: root/models/gpg_key.go
diff options
context:
space:
mode:
Diffstat (limited to 'models/gpg_key.go')
-rw-r--r--models/gpg_key.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/models/gpg_key.go b/models/gpg_key.go
index 5763ef8403..d39cc54ce6 100644
--- a/models/gpg_key.go
+++ b/models/gpg_key.go
@@ -127,7 +127,7 @@ func AddGPGKey(ownerID int64, content string) (*GPGKey, error) {
//Get DB session
sess := x.NewSession()
- defer sessionRelease(sess)
+ defer sess.Close()
if err = sess.Begin(); err != nil {
return nil, err
}
@@ -267,7 +267,7 @@ func DeleteGPGKey(doer *User, id int64) (err error) {
}
sess := x.NewSession()
- defer sessionRelease(sess)
+ defer sess.Close()
if err = sess.Begin(); err != nil {
return err
}