diff --git a/app/enterprise.go b/app/enterprise.go index ab434dadfa..c1d2a778d4 100644 --- a/app/enterprise.go +++ b/app/enterprise.go @@ -238,4 +238,7 @@ func (s *Server) initEnterprise() { } }) } + if cloudInterface != nil { + s.Cloud = cloudInterface(s) + } } diff --git a/app/server.go b/app/server.go index 7bf6de85ba..a98668276f 100644 --- a/app/server.go +++ b/app/server.go @@ -462,14 +462,6 @@ func NewServer(options ...Option) (*Server, error) { }) - // This enterprise init should happen after the store is set - // but we don't want to move the s.initEnterprise() call because - // we had side-effects with that in the past and needs further - // investigation - if cloudInterface != nil { - s.Cloud = cloudInterface(s) - } - s.telemetryService = telemetry.New(s, s.Store, s.SearchEngine, s.Log) emailService, err := email.NewService(email.ServiceConfig{