mirror of
https://github.com/router-for-me/CLIProxyAPI.git
synced 2026-02-19 04:40:52 +08:00
fix(management): exclude disabled runtime-only auths from file entries
This commit is contained in:
@@ -293,6 +293,9 @@ func (h *Handler) buildAuthFileEntry(auth *coreauth.Auth) gin.H {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
runtimeOnly := isRuntimeOnlyAuth(auth)
|
runtimeOnly := isRuntimeOnlyAuth(auth)
|
||||||
|
if runtimeOnly && (auth.Disabled || auth.Status == coreauth.StatusDisabled) {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
path := strings.TrimSpace(authAttribute(auth, "path"))
|
path := strings.TrimSpace(authAttribute(auth, "path"))
|
||||||
if path == "" && !runtimeOnly {
|
if path == "" && !runtimeOnly {
|
||||||
return nil
|
return nil
|
||||||
|
|||||||
Reference in New Issue
Block a user