aboutsummaryrefslogtreecommitdiff
path: root/pkg/context/context.go
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/context/context.go')
-rw-r--r--pkg/context/context.go14
1 files changed, 9 insertions, 5 deletions
diff --git a/pkg/context/context.go b/pkg/context/context.go
index ed97395b..579d81d0 100644
--- a/pkg/context/context.go
+++ b/pkg/context/context.go
@@ -21,11 +21,11 @@ import (
log "gopkg.in/clog.v1"
"gopkg.in/macaron.v1"
- "github.com/gogits/gogs/models"
- "github.com/gogits/gogs/models/errors"
- "github.com/gogits/gogs/pkg/auth"
- "github.com/gogits/gogs/pkg/form"
- "github.com/gogits/gogs/pkg/setting"
+ "github.com/gogs/gogs/models"
+ "github.com/gogs/gogs/models/errors"
+ "github.com/gogs/gogs/pkg/auth"
+ "github.com/gogs/gogs/pkg/form"
+ "github.com/gogs/gogs/pkg/setting"
)
// Context represents context of a request.
@@ -68,6 +68,10 @@ func (c *Context) RequireSimpleMDE() {
c.Require("SimpleMDE")
}
+func (c *Context) RequireAutosize() {
+ c.Require("Autosize")
+}
+
// FormErr sets "Err_xxx" field in template data.
func (c *Context) FormErr(names ...string) {
for i := range names {