mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-18 22:36:43 +09:00
add csrf check
This commit is contained in:
1 parent
01e781dedb
commit
076fc98d98
18 files changed
+208
-46
No files matched your search
@@ -242,8 +242,11 @@ func (r *Render) HTMLString(name string, binding interface{}, htmlOpt ...HTMLOpt
|
||||
}
|
||||
}
|
||||
|
||||
func (r *Render) Error(status int) {
|
||||
func (r *Render) Error(status int, message ...string) {
|
||||
r.WriteHeader(status)
|
||||
if len(message) > 0 {
|
||||
r.Write([]byte(message[0]))
|
||||
}
|
||||
}
|
||||
|
||||
func (r *Render) Redirect(location string, status ...int) {
|
||||
|
||||
Reference in new issue
Block a user