Start protecting the Api

This commit is contained in:
Paul Schneider 2026-06-06 21:30:41 +01:00
commit 57adfc82a5
5 changed files with 11 additions and 4 deletions

View file

@ -342,7 +342,7 @@ public static class HostingExtensions
{
return (context, _) =>
{
foreach (String scope in new string[] { "blog", "admin", "contract", "com" })
foreach (String scope in Constants.BuildInApiScopes)
{
var existentScope = context.Set<ApiScope>().FirstOrDefault(b => b.Name == scope);
if (existentScope == null)