summaryrefslogtreecommitdiffstats
path: root/app/scheme.go
diff options
context:
space:
mode:
Diffstat (limited to 'app/scheme.go')
-rw-r--r--app/scheme.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/app/scheme.go b/app/scheme.go
index c44690954..f070e36f8 100644
--- a/app/scheme.go
+++ b/app/scheme.go
@@ -142,10 +142,16 @@ func (a *App) GetChannelsForScheme(scheme *model.Scheme, offset int, limit int)
}
func (a *App) IsPhase2MigrationCompleted() *model.AppError {
+ if a.phase2PermissionsMigrationComplete {
+ return nil
+ }
+
if result := <-a.Srv.Store.System().GetByName(model.MIGRATION_KEY_ADVANCED_PERMISSIONS_PHASE_2); result.Err != nil {
return model.NewAppError("App.IsPhase2MigrationCompleted", "app.schemes.is_phase_2_migration_completed.not_completed.app_error", nil, result.Err.Error(), http.StatusNotImplemented)
}
+ a.phase2PermissionsMigrationComplete = true
+
return nil
}