From 0564cc42717f9332fe4d6a40a44e92c9e5ad46ad Mon Sep 17 00:00:00 2001 From: Martin Kraft Date: Sun, 16 Feb 2020 11:07:25 -0500 Subject: [PATCH] =?UTF-8?q?MM-21150:=20Re-create=20the=20workers=20so=20th?= =?UTF-8?q?at=20the=20EE=20workers=20are=20non-nil=20up=E2=80=A6=20(#13523?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * MM-21150: Re-create the workers so that the EE workers are non-nil upon uploading a license. * MM-21150: Updates from Srv field to method. Co-authored-by: mattermod --- api4/license.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/api4/license.go b/api4/license.go index 9b6463d8b1..a038023bb0 100644 --- a/api4/license.go +++ b/api4/license.go @@ -98,6 +98,11 @@ func addLicense(c *Context, w http.ResponseWriter, r *http.Request) { return } + if *c.App.Config().JobSettings.RunJobs { + c.App.Srv().Jobs.Workers = c.App.Srv().Jobs.InitWorkers() + c.App.Srv().Jobs.StartWorkers() + } + c.LogAudit("success") w.Write([]byte(license.ToJson())) }