From c085ea9b7d26143ba5b43d901dc36f5adfc9ccaf Mon Sep 17 00:00:00 2001 From: Quaternions Date: Thu, 26 Dec 2024 17:54:42 -0800 Subject: [PATCH] submissions: implement ScriptWrite permission --- pkg/service/security.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkg/service/security.go b/pkg/service/security.go index 819f624..addc5a9 100644 --- a/pkg/service/security.go +++ b/pkg/service/security.go @@ -15,6 +15,8 @@ var ( ) var ( + // has ScriptWrite + RoleQuat int32 = 255 // has SubmissionPublish RoleMapAdmin int32 = 128 // has SubmissionReview @@ -80,6 +82,9 @@ func (svc SecurityHandler) HandleCookieAuth(ctx context.Context, operationName a // fix this when roblox udpates group roles for _, r := range role.Roles { + if RoleQuat <= r.Rank { + roles.ScriptWrite = true + } if RoleMapAdmin <= r.Rank { roles.SubmissionRelease = true }