summaryrefslogtreecommitdiffstats
path: root/cmd/serv.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2017-04-19 11:45:01 +0800
committerGitHub <noreply@github.com>2017-04-19 11:45:01 +0800
commit2eeae84cbd80544157a82c7f031489eaaceaa873 (patch)
treea275f41a3bb552df39724d4eca3dcdffe47dff8f /cmd/serv.go
parentf42ec6120e8a2830407027020b65391ebf8e7f59 (diff)
downloadgitea-2eeae84cbd80544157a82c7f031489eaaceaa873.tar.gz
gitea-2eeae84cbd80544157a82c7f031489eaaceaa873.zip
Add internal routes for ssh hook comands (#1471)
* add internal routes for ssh hook comands * fix lint * add comment on why package named private not internal but the route name is internal * add comment above package private why package named private not internal but the route name is internal * remove exp time on internal access * move routes from /internal to /api/internal * add comment and defer on UpdatePublicKeyUpdated
Diffstat (limited to 'cmd/serv.go')
-rw-r--r--cmd/serv.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/cmd/serv.go b/cmd/serv.go
index d7e89ab98d..f7d025c68e 100644
--- a/cmd/serv.go
+++ b/cmd/serv.go
@@ -16,6 +16,7 @@ import (
"code.gitea.io/gitea/models"
"code.gitea.io/gitea/modules/log"
+ "code.gitea.io/gitea/modules/private"
"code.gitea.io/gitea/modules/setting"
"github.com/Unknwon/com"
@@ -318,7 +319,7 @@ func runServ(c *cli.Context) error {
// Update user key activity.
if keyID > 0 {
- if err = models.UpdatePublicKeyUpdated(keyID); err != nil {
+ if err = private.UpdatePublicKeyUpdated(keyID); err != nil {
fail("Internal error", "UpdatePublicKey: %v", err)
}
}