]> source.dussan.org Git - gitea.git/commitdiff
#2646 fix panic on pushing repositor
authorUnknwon <u@gogs.io>
Wed, 17 Feb 2016 20:17:52 +0000 (15:17 -0500)
committerUnknwon <u@gogs.io>
Wed, 17 Feb 2016 20:17:52 +0000 (15:17 -0500)
cmd/update.go

index 1d27fb3e7be5a8f048b91ccbd66c278b8d226fe7..30f778f229d0a62c05d5f5f5476b43f693dc19a6 100644 (file)
@@ -29,13 +29,13 @@ func runUpdate(c *cli.Context) {
                setting.CustomConf = c.String("config")
        }
 
+       setup("update.log")
+
        if len(os.Getenv("SSH_ORIGINAL_COMMAND")) == 0 {
                log.GitLogger.Trace("SSH_ORIGINAL_COMMAND is empty")
                return
        }
 
-       setup("update.log")
-
        args := c.Args()
        if len(args) != 3 {
                log.GitLogger.Fatal(2, "Arguments received are not equal to three")