Prevent system_admin role mistake (#4405)

Этот коммит содержится в:
Christopher Speller
2016-11-01 12:05:48 -04:00
коммит произвёл Corey Hulen
родитель 92642bab68
Коммит aa6cb03b20
3 изменённых файлов: 20 добавлений и 2 удалений

Просмотреть файл

@@ -337,6 +337,11 @@ func IsValidUserRoles(userRoles string) bool {
}
}
// Exclude just the system_admin role explicitly to prevent mistakes
if len(roles) == 1 && roles[0] == "system_admin" {
return false
}
return true
}