From 7e2b539de484ac4f2e97eafce6b8d63ffa2caf13 Mon Sep 17 00:00:00 2001 From: Thomas Balthazar Date: Tue, 24 May 2016 15:07:42 +0200 Subject: Max_File_Size setting in System Console > File Settings (#3070) --- api/license.go | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'api/license.go') diff --git a/api/license.go b/api/license.go index 1dbb2b281..f9ecce486 100644 --- a/api/license.go +++ b/api/license.go @@ -5,12 +5,13 @@ package api import ( "bytes" - l4g "github.com/alecthomas/log4go" - "github.com/mattermost/platform/model" - "github.com/mattermost/platform/utils" "io" "net/http" "strings" + + l4g "github.com/alecthomas/log4go" + "github.com/mattermost/platform/model" + "github.com/mattermost/platform/utils" ) const ( @@ -48,7 +49,7 @@ func LoadLicense() { func addLicense(c *Context, w http.ResponseWriter, r *http.Request) { c.LogAudit("attempt") - err := r.ParseMultipartForm(model.MAX_FILE_SIZE) + err := r.ParseMultipartForm(*utils.Cfg.FileSettings.MaxFileSize) if err != nil { http.Error(w, err.Error(), http.StatusInternalServerError) return -- cgit v1.2.3-1-g7c22