mirror of
https://github.com/photoprism/photoprism.git
synced 2025-09-26 21:01:58 +08:00
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
@@ -6,7 +6,7 @@ import (
|
||||
"github.com/photoprism/photoprism/pkg/list"
|
||||
)
|
||||
|
||||
// Scope sanitizes a string that contains authentication scope identifiers.
|
||||
// Scope sanitizes a string that contains auth scope identifiers.
|
||||
// Callers should use acl.ScopeAttrPermits / acl.ScopePermits for authorization checks.
|
||||
func Scope(s string) string {
|
||||
if s == "" {
|
||||
@@ -16,7 +16,7 @@ func Scope(s string) string {
|
||||
return list.ParseAttr(strings.ToLower(s)).String()
|
||||
}
|
||||
|
||||
// Scopes sanitizes authentication scope identifiers and returns them as string slice.
|
||||
// Scopes sanitizes auth scope identifiers and returns them as strings.
|
||||
// Callers should use acl.ScopeAttrPermits / acl.ScopePermits for authorization checks.
|
||||
func Scopes(s string) []string {
|
||||
if s == "" {
|
||||
|
Reference in New Issue
Block a user