summaryrefslogtreecommitdiffstats
path: root/modules/auth
diff options
context:
space:
mode:
authorUnknown <joe2010xtmf@163.com>2014-05-06 16:28:52 -0400
committerUnknown <joe2010xtmf@163.com>2014-05-06 16:28:52 -0400
commit8ca14e210959b9316a4eed6e127de1eb775fda74 (patch)
tree93af1213d80c700838b1c41eb1c1c9ffcbfd60d6 /modules/auth
parent7cb5a15c9b7a2a118d756d15cb745743f207a318 (diff)
downloadgitea-8ca14e210959b9316a4eed6e127de1eb775fda74.tar.gz
gitea-8ca14e210959b9316a4eed6e127de1eb775fda74.zip
Improve delete SSH key
Diffstat (limited to 'modules/auth')
-rw-r--r--modules/auth/issue.go15
-rw-r--r--modules/auth/release.go15
2 files changed, 0 insertions, 30 deletions
diff --git a/modules/auth/issue.go b/modules/auth/issue.go
index 85be12d2b5..e8f8ac2011 100644
--- a/modules/auth/issue.go
+++ b/modules/auth/issue.go
@@ -11,7 +11,6 @@ import (
"github.com/go-martini/martini"
"github.com/gogits/gogs/modules/base"
- "github.com/gogits/gogs/modules/log"
"github.com/gogits/gogs/modules/middleware/binding"
)
@@ -31,20 +30,6 @@ func (f *CreateIssueForm) Name(field string) string {
}
func (f *CreateIssueForm) Validate(errors *binding.BindingErrors, req *http.Request, context martini.Context) {
- if req.Method == "GET" || errors.Count() == 0 {
- return
- }
-
data := context.Get(reflect.TypeOf(base.TmplData{})).Interface().(base.TmplData)
- data["HasError"] = true
- AssignForm(f, data)
-
- if len(errors.Overall) > 0 {
- for _, err := range errors.Overall {
- log.Error("CreateIssueForm.Validate: %v", err)
- }
- return
- }
-
validate(errors, data, f)
}
diff --git a/modules/auth/release.go b/modules/auth/release.go
index 9855c30338..7774b914a0 100644
--- a/modules/auth/release.go
+++ b/modules/auth/release.go
@@ -11,7 +11,6 @@ import (
"github.com/go-martini/martini"
"github.com/gogits/gogs/modules/base"
- "github.com/gogits/gogs/modules/log"
"github.com/gogits/gogs/modules/middleware/binding"
)
@@ -32,20 +31,6 @@ func (f *NewReleaseForm) Name(field string) string {
}
func (f *NewReleaseForm) Validate(errors *binding.BindingErrors, req *http.Request, context martini.Context) {
- if req.Method == "GET" || errors.Count() == 0 {
- return
- }
-
data := context.Get(reflect.TypeOf(base.TmplData{})).Interface().(base.TmplData)
- data["HasError"] = true
- AssignForm(f, data)
-
- if len(errors.Overall) > 0 {
- for _, err := range errors.Overall {
- log.Error("NewReleaseForm.Validate: %v", err)
- }
- return
- }
-
validate(errors, data, f)
}