MCPcopy Create free account

hub / github.com/Prejudice-Studio/Twilight / functions

Functions2,686 in github.com/Prejudice-Studio/Twilight

↓ 2 callersMethodhandleBatchToggleUsers
(w http.ResponseWriter, r *http.Request, enable bool)
internal/api/batch_user_handlers.go:21
↓ 2 callersFunctionhandleBindEmby
()
webui/src/app/(main)/settings/page.tsx:502
↓ 2 callersFunctionhandleCascadeToggle
(enable: boolean)
webui/src/app/(main)/admin/invite/page.tsx:237
↓ 2 callersFunctionhandleCopy
(code: string)
webui/src/app/(main)/invite/page.tsx:231
↓ 2 callersFunctionhandleCopyUrl
(url: string, key: string)
webui/src/app/(main)/settings/page.tsx:688
↓ 2 callersFunctionhandleDelete
(code: Regcode)
webui/src/app/(main)/admin/regcodes/page.tsx:228
↓ 2 callersMethodhandleDetachExpiredInviteChild
(w http.ResponseWriter, r *http.Request, params Params)
internal/api/invite_handlers.go:234
↓ 2 callersFunctionhandleEmbyToggle
(user: UserInfo, enable: boolean)
webui/src/app/(main)/admin/users/page.tsx:1049
↓ 2 callersFunctionhandleGitUpdate
(dryRun = false)
webui/src/app/(main)/admin/config/page.tsx:1547
↓ 2 callersFunctionhandleRenameType
()
webui/src/app/(main)/admin/tickets/page.tsx:105
↓ 2 callersFunctionhandleRevoke
(code: InviteCodeItem)
webui/src/app/(main)/invite/page.tsx:240
↓ 2 callersFunctionhandleSaveNote
(code: string)
webui/src/app/(main)/admin/regcodes/page.tsx:356
↓ 2 callersMethodhandleSchedulerSchedule
(w http.ResponseWriter, r *http.Request, params Params)
internal/api/scheduler_handlers.go:110
↓ 2 callersFunctionhandleSelectedEmbyToggle
(enable: boolean)
webui/src/app/(main)/admin/users/page.tsx:1312
↓ 2 callersFunctionhandleSelectedRefreshStatus
(scope: "telegram" | "emby")
webui/src/app/(main)/admin/users/page.tsx:1344
↓ 2 callersFunctionhandleSelectedToggleActive
(enable: boolean)
webui/src/app/(main)/admin/users/page.tsx:1235
↓ 2 callersFunctionhandleToggleActive
(code: Regcode)
webui/src/app/(main)/admin/regcodes/page.tsx:374
↓ 2 callersMethodhandleUpload
(w http.ResponseWriter, r *http.Request, kind string)
internal/api/upload_handlers.go:197
↓ 2 callersFunctionhandleViewAllPage
(dir: number)
webui/src/app/(main)/bangumi/page.tsx:141
↓ 2 callersFunctionhandleVisualChange
( field: "lightBlur" | "darkBlur" | "lightOpacity" | "darkOpacity", value: number )
webui/src/app/(main)/settings/appearance/page.tsx:246
↓ 2 callersFunctionhasHeader
(headers: Record<string, string>, name: string)
webui/src/lib/api-request.ts:98
↓ 2 callersFunctionhasItem
(preset: string)
webui/src/app/(main)/admin/config/page.tsx:330
↓ 2 callersFunctionhashPasswordWithSalt
(password, salt string, iterations int)
internal/security/password.go:91
↓ 2 callersFunctionhslVar
(hex: string)
webui/src/lib/theme-custom.ts:103
↓ 2 callersFunctionint64ListValue
(value string)
internal/config/config.go:1579
↓ 2 callersMethodint64ListValue
(fallback []int64, keys ...string)
internal/config/config.go:1351
↓ 2 callersMethodint64Value
(fallback int64, keys ...string)
internal/config/config.go:1218
↓ 2 callersFunctionintListValue
(value string)
internal/config/config.go:1423
↓ 2 callersMethodintListValue
(fallback []int, keys ...string)
internal/config/config.go:1370
↓ 2 callersFunctionintsToAny
(values []int)
internal/api/config_admin.go:1395
↓ 2 callersFunctioninvalidateRequestsCache
()
webui/src/app/(main)/admin/requests/page.tsx:69
↓ 2 callersFunctioninvalidateRequestsCache
()
webui/src/app/(main)/admin/telegram-rebind-requests/page.tsx:45
↓ 2 callersFunctionisAbortError
(error: unknown)
webui/src/lib/api-request.ts:65
↓ 2 callersFunctionisActivePath
(pathname: string, href: string)
webui/src/components/layout/sidebar.tsx:125
↓ 2 callersFunctionisChanged
(a: unknown, b: unknown)
webui/src/components/admin/config-section-editor.tsx:40
↓ 2 callersFunctionisDuplicateDatabaseError
(err error)
internal/store/store.go:673
↓ 2 callersFunctionisIntegerString
(value string)
internal/api/config_admin.go:1407
↓ 2 callersFunctionisNormalOps
(k: { allow_query: boolean })
webui/src/app/(main)/settings/apikey/page.tsx:60
↓ 2 callersFunctionisSafeUrl
(raw: string)
webui/src/lib/safe-render.tsx:10
↓ 2 callersFunctionisSyntheticEmbyID
(id string, uid int64)
internal/api/scheduler_runner.go:750
↓ 2 callersFunctionisTimeoutError
(error: unknown)
webui/src/lib/api-request.ts:75
↓ 2 callersFunctionisUndefinedDatabaseError
(err error)
internal/store/store.go:665
↓ 2 callersFunctionisUserSelected
(user: UserInfo)
webui/src/app/(main)/admin/users/page.tsx:371
↓ 2 callersFunctionkeyRows
(locale: TextLocale, keys: string[], kind: "config" | "env")
webui/src/components/developer-js-docs-panel.tsx:909
↓ 2 callersMethodkickEmbySessions
kickEmbySessions 踢出某 Emby 用户当前的全部在线会话(逐个 /Sessions/{id}/Logout), 返回成功登出的会话数。Emby 未配置或 embyID 为空时返回 0。供按 uid / 按 emby_id 两条 踢人入口共用,避免重复遍历 /Sessions 的逻辑
internal/api/admin_emby_user_actions.go:12
↓ 2 callersMethodkickNoEmbyUsers
(opts?: { dryRun?: boolean; confirm?: string; minDays?: number; preservePendingRegister?: bool
webui/src/lib/api.ts:1730
↓ 2 callersMethodkickUnboundGroupMembers
一键踢出群里未绑定 Web 账号的成员。``dryRun=true`` 时只统计目标,不实际踢。
webui/src/lib/api.ts:1662
↓ 2 callersFunctionleaves
(obj, prefix = "", out = {})
webui/check_placeholders.mjs:8
↓ 2 callersFunctionlinesToStrings
(lines []config.Line)
internal/api/config_admin.go:1348
↓ 2 callersMethodlistDeveloperJSPresets
()
webui/src/lib/api.ts:1846
↓ 2 callersFunctionlistFieldWantsInts
(key string)
internal/api/config_admin.go:1403
↓ 2 callersFunctionlookupMessage
(locale: Locale, key: MessageKey)
webui/src/lib/i18n.tsx:85
↓ 2 callersFunctionmaskAPIKey
(key string)
internal/api/app.go:1464
↓ 2 callersFunctionmaskTOMLSecrets
maskTOMLSecrets 对磁盘原文 TOML 做行级密钥遮蔽:凡是落在某 section 下、且被 configSectionDefs 标记为 Type=="secret" 的非空字段,整行重写为 key = "<哨兵>"。 与 maskConfigSecrets(作用于 values)同口
internal/api/config_admin.go:96
↓ 2 callersFunctionmatchesSearch
(haystacks: string[], q: string)
webui/src/components/admin/emby-device-audit-panel.tsx:118
↓ 2 callersMethodmergeFile
(path string)
internal/config/config.go:1097
↓ 2 callersMethodmigrateDatabase
(payload: { source_driver?: "json" | "postgres"; target_driver: "json" | "postgres"; dry_run?: boo
webui/src/lib/api.ts:1351
↓ 2 callersFunctionminInt
(a, b int)
internal/api/runtime_logs.go:176
↓ 2 callersFunctionnewRateLimiter
(redisClient *redis.Client)
internal/api/ratelimit.go:33
↓ 2 callersFunctionnewRedisClient
(cfg config.Config)
internal/api/app.go:255
↓ 2 callersFunctionnewRuntimeLogBuffer
(limit int)
internal/api/runtime_logs.go:170
↓ 2 callersFunctionnormalizeAssetUrl
(url?: string)
webui/src/app/(main)/admin/users/page.tsx:77
↓ 2 callersMethodnormalizeBackgroundAssetCssUrlValue
(value?: string | null)
webui/src/lib/api.ts:160
↓ 2 callersFunctionnormalizeConfigContent
(configFile, content string)
internal/api/config_admin.go:525
↓ 2 callersFunctionnormalizeEmbyName
(name string)
internal/api/scheduler_runner.go:746
↓ 2 callersFunctionnormalizeRefreshScope
normalizeRefreshScope 归一化刷新范围:telegram 仅刷新 TG 用户名、emby 仅核对 Emby 状态、其余(含空)默认 both 两者都刷。让 TG 同步与 Emby 同步可以分开触发。
internal/api/admin_user_refresh.go:34
↓ 2 callersFunctionnormalizeRoleValue
normalizeRoleValue 把任意 JSON 数值收成已知 role 整数。 仅 RoleAdmin / RoleNormal / RoleWhitelist / RoleUnrecognized 视为合法。 用于 admin update / set-role 等所有写 user.Rol
internal/api/handlers.go:1981
↓ 2 callersFunctionnormalizeSchedulerRunTimestamps
(run *SchedulerRun)
internal/store/scheduler.go:271
↓ 2 callersMethodnormalizeSchedulerRuntimeParams
(jobID string, params map[string]any)
internal/api/scheduler_handlers.go:196
↓ 2 callersFunctionnormalizeStoreDriver
(driver string)
internal/api/app.go:315
↓ 2 callersFunctionnormalizeTelegramCustomCommand
(value string)
internal/api/config_admin.go:1372
↓ 2 callersFunctionnormalizeTelegramUsername
(username string)
internal/store/store.go:1837
↓ 2 callersFunctionnormalizedRuntimeDriver
(driver string)
internal/api/storage_guard.go:13
↓ 2 callersFunctionnormalizedRuntimeStateFile
(path string)
internal/api/storage_guard.go:39
↓ 2 callersFunctionopenActionDialog
(request: TelegramRebindRequest, action: "approve" | "reject")
webui/src/app/(main)/admin/telegram-rebind-requests/page.tsx:69
↓ 2 callersFunctionopenBulkActionDialog
(action: "approve" | "reject")
webui/src/app/(main)/admin/telegram-rebind-requests/page.tsx:76
↓ 2 callersFunctionopenEditDialog
(code: Regcode)
webui/src/app/(main)/admin/regcodes/page.tsx:399
↓ 2 callersFunctionopenUsageDialog
(code: Regcode)
webui/src/app/(main)/admin/regcodes/page.tsx:437
↓ 2 callersFunctionparseClientIPHeader
(value string)
internal/api/app.go:1208
↓ 2 callersFunctionparseTelegramCommandRepliesList
(parts []string)
internal/config/config.go:1635
↓ 2 callersFunctionph
(s)
webui/check_placeholders.mjs:16
↓ 2 callersFunctionpostgresTargetInfo
(dsn string)
internal/store/store.go:687
↓ 2 callersFunctionpreloadLocale
(locale: Locale)
webui/src/lib/i18n.tsx:32
↓ 2 callersMethodpreviewCode
(ctx context.Context, code string, user store.User)
internal/api/business.go:833
↓ 2 callersFunctionpreviewMigration
(openConfirm = false)
webui/src/app/(main)/admin/database/page.tsx:271
↓ 2 callersMethodprobeEmbyUrl
(url: string)
webui/src/lib/api.ts:625
↓ 2 callersFunctionprotectedAdminConfigLine
(trimmed string)
internal/api/config_admin.go:712
↓ 2 callersFunctionproviderID
(item map[string]any, key string)
internal/api/emby_inventory.go:226
↓ 2 callersFunctionpublicTelegramLinkList
(values []string)
internal/api/handlers.go:1261
↓ 2 callersFunctionpublicTelegramLinks
(groupIDs, channelIDs []string)
internal/api/handlers.go:1247
↓ 2 callersFunctionquotePostgresIdentifier
(value string)
internal/store/store.go:727
↓ 2 callersFunctionreadReply
(r *bufio.Reader)
internal/redis/redis.go:258
↓ 2 callersFunctionreadStoredPerPage
(key: string, fallback: number, allowed: number[])
webui/src/lib/utils.ts:10
↓ 2 callersFunctionreadUntil
(marker: string, from: number)
webui/src/lib/safe-render.tsx:41
↓ 2 callersMethodrecordViolation
recordViolation logs a code violation and applies the configured punitive action. 入参 ctx 通常来自 r.Context(),用于控制审计写入与本地操作的取消语义; 但 disable_user / disable
internal/api/business.go:900
↓ 2 callersFunctionrefreshRegisterAvailability
()
webui/src/app/(auth)/register/page.tsx:116
↓ 2 callersMethodrefreshUserExternalStatus
refreshUserExternalStatus 主动核对并回写用户在 Telegram 与 Emby 的当前状态: - Telegram:用 getChat 拉最新 @username(被动刷新只在用户给 Bot 发消息时触发, 这里给管理员一个强制拉取入口);取不到用户名时保留旧值不清空,避免
internal/api/admin_user_refresh.go:53
↓ 2 callersMethodregCodeFormatForType
(codeType int, explicit string)
internal/api/business.go:652
↓ 2 callersFunctionregCodeMatchesUser
(reg RegCode, user User)
internal/store/store.go:1822
↓ 2 callersFunctionregCodeRandomAlgorithmOptions
()
internal/api/config_admin.go:863
← previousnext →801–900 of 2,686, ranked by callers