Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/KunMoe/kun-galgame-forum
/ functions
Functions
2,016 in github.com/KunMoe/kun-galgame-forum
⨍
Functions
2,016
◇
Types & classes
1,043
↓ 610 callers
Method
Error
()
apps/api/internal/user/oauth/client.go:44
↓ 185 callers
Method
Get
Get performs a GET request to the wiki service.
apps/api/internal/galgame/client/client.go:159
↓ 135 callers
Method
Scan
(src any)
apps/api/internal/topic/model/topic_draft.go:27
↓ 58 callers
Method
Put
(value []byte)
apps/api/internal/infrastructure/markdown/markdown.go:383
↓ 56 callers
Method
Hydrate
Hydrate looks up `ids` and returns a *total* map (every id in `ids` is present, missing/unknown ids get a Placeholder). Mapper code can then do `m[r.U
apps/api/pkg/userclient/hydrate.go:38
↓ 50 callers
Method
Error
()
apps/api/pkg/errors/errors.go:13
↓ 37 callers
Method
Offset
()
apps/api/pkg/utils/pagination.go:10
↓ 35 callers
Function
envOrDefault
(key, fallback string)
apps/api/pkg/config/config.go:249
↓ 34 callers
Method
Delete
(ctx context.Context, key string)
apps/api/internal/infrastructure/storage/s3.go:65
↓ 33 callers
Method
AdjustMoemoepoint
(ctx context.Context, userID, delta int, reason, ref, idempotencyKey string)
apps/api/internal/moemoepoint/pusher.go:49
↓ 33 callers
Method
DB
DB exposes the connection for service-owned transactions.
apps/api/internal/galgame/repository/rating_repo.go:20
↓ 31 callers
Function
useMessage
( messageData: number | string, type: KunMessageType, duration = 3000, richText = false, position: K
apps/web/app/composables/useMessage.ts:10
↓ 25 callers
Method
Do
(req *http.Request)
apps/api/pkg/artifactclient/gen/artifact_client.gen.go:179
↓ 25 callers
Method
User
User is the single-id convenience. Returns (zero, false) for unknown ids.
apps/api/pkg/userclient/userclient.go:228
↓ 22 callers
Method
Delete
(userID, id int)
apps/api/internal/topic/service/draft_service.go:94
↓ 22 callers
Method
ProxyWriteWithToken
ProxyWriteWithToken returns a Fiber handler that forwards a POST/PUT/DELETE to wiki with the session-stored OAuth access token. The token is taken fro
apps/api/internal/galgame/handler/wiki_handler.go:72
↓ 21 callers
Method
DB
()
apps/api/internal/topic/repository/poll_repo.go:19
↓ 20 callers
Method
Create
(topic *model.Topic)
apps/api/internal/topic/repository/topic_repo.go:51
↓ 19 callers
Method
FindByID
(id int)
apps/api/internal/topic/repository/poll_repo.go:23
↓ 18 callers
Function
collectQuery
────────────────────────────────────────── Query helpers ────────────────────────────────────────── collectQuery converts the Fiber request query args
apps/api/internal/galgame/handler/entity_handler.go:176
↓ 17 callers
Function
userBriefToDTO
userBriefToDTO maps a userclient.User to the dto.UserBrief projection.
apps/api/internal/galgame/service/resource_mapper.go:73
↓ 16 callers
Function
formatTimeDifference
(pastTime: number | Date | string)
apps/web/shared/utils/time.ts:11
↓ 14 callers
Method
Delete
Delete removes an owner's collection. The default collection is protected. favorite_count is kept accurate for games held only in this collection; own
apps/api/internal/galgame/service/collection_service.go:133
↓ 14 callers
Method
FindByID
FindByID loads a single comment.
apps/api/internal/toolset/repository/comment_repo.go:96
↓ 14 callers
Method
Run
Run executes one sync cycle. Safe to call concurrently — events use SETNX guards so duplicate processing only re-writes the cursor. Designed to be che
apps/api/internal/galgame/service/wiki_message_sync.go:90
↓ 13 callers
Method
FindByID
────────────────────────────────────────── Reads — single rating ────────────────────────────────────────── FindByID returns a single rating row. Retu
apps/api/internal/galgame/repository/rating_repo.go:38
↓ 13 callers
Function
getPreferredLanguageText
( language: KunLanguage, locale?: Language )
apps/web/shared/utils/getPreferredLanguageText.ts:1
↓ 13 callers
Function
getReleaseDateText
( releaseDate?: string | null, releaseDateTBA?: boolean )
apps/web/shared/utils/time.ts:128
↓ 12 callers
Method
GetBatchPublic
GetBatchPublic is the cookie-aware batch fetch for any public list / feed enrichment path: enriches kungal-local IDs with wiki briefs while honouring
apps/api/internal/galgame/client/client.go:501
↓ 12 callers
Function
isValidName
(name: string)
apps/web/shared/utils/validate.ts:22
↓ 11 callers
Method
CreateGalgameMessageWithContent
CreateGalgameMessageWithContent is the variant that records a content preview (used by resource liked/expired notifications). Dedup applies on (sender
apps/api/internal/galgame/service/interaction.go:41
↓ 11 callers
Method
Init
────────────────────────────────────────── Init — POST /toolset/:id/upload/init ────────────────────────────────────────── Init validates the file, re
apps/api/internal/toolset/service/upload_service.go:92
↓ 11 callers
Function
Render
Render converts markdown to HTML with all custom transformations.
apps/api/internal/infrastructure/markdown/markdown.go:236
↓ 11 callers
Method
Update
Update patches arbitrary columns on a rating row.
apps/api/internal/galgame/repository/rating_repo.go:155
↓ 11 callers
Function
clamp
(v: number, lo: number, hi: number)
apps/web/algorithms/GalgameRatingAlg.ts:86
↓ 11 callers
Function
del
del runs a DELETE/UPDATE and PROPAGATES the error (unlike a fire-and-forget Exec) so any mid-transaction failure aborts and rolls back the whole purge
apps/api/internal/admin/repository/purge_repo.go:350
↓ 10 callers
Method
GetWithToken
GetWithToken is like Get but attaches a Bearer token. Used by endpoints whose response shape depends on the caller's identity: - /galgame/batch with B
apps/api/internal/galgame/client/client.go:170
↓ 10 callers
Method
ToCards
ToCards converts wiki galgame items into enriched GalgameCard DTOs, batch- loading users (from OAuth) and local stats once.
apps/api/internal/galgame/service/galgame_enricher.go:81
↓ 10 callers
Function
isValidEmail
(email: string)
apps/web/shared/utils/validate.ts:17
↓ 10 callers
Function
optionalUID
optionalUID returns the logged-in user's ID from OptionalAuth middleware, or 0 if not authenticated.
apps/api/internal/galgame/handler/resource_handler.go:101
↓ 10 callers
Function
secsAgo
(n: number)
apps/web/shared/utils/time.spec.ts:24
↓ 10 callers
Function
toYMD
(raw?: string | null)
apps/web/shared/utils/time.ts:95
↓ 9 callers
Method
Create
────────────────────────────────────────── Create — POST /galgame ────────────────────────────────────────── Create forwards the payload to wiki, then
apps/api/internal/galgame/service/galgame_service.go:82
↓ 9 callers
Method
Delete
Delete — DELETE /doc/tag
apps/api/internal/doc/service/tag_service.go:44
↓ 9 callers
Function
formatFileSize
(size: number)
apps/web/shared/utils/format.ts:1
↓ 9 callers
Function
formatNumber
(num: number)
apps/web/shared/utils/format.ts:16
↓ 9 callers
Function
rewriteBanners
rewriteBanners walks the wiki response JSON and, for every object carrying U2 hash fields (`effective_banner_hash` / per-row `image_hash` + `sort_orde
apps/api/internal/galgame/client/banner.go:48
↓ 9 callers
Function
truncate
truncate trims `s` to `maxLen` runes (rune-aware, avoids splitting multibyte chars).
apps/api/internal/topic/service/interaction_helpers.go:145
↓ 9 callers
Function
withSFWFilter
withSFWFilter clones q and pins `content_limit` per the wiki NSFW protocol (see docs/galgame_wiki/00-handbook-for-downstream.md §16). Both modes are
apps/api/internal/galgame/service/official_service.go:212
↓ 8 callers
Method
Award
Award adjusts the user's unified balance on OAuth and syncs the local cache. Fire-and-forget: it returns immediately and does the OAuth call + cache m
apps/api/internal/moemoepoint/pusher.go:71
↓ 8 callers
Method
Delete
Delete removes a comment by reference.
apps/api/internal/toolset/repository/comment_repo.go:122
↓ 8 callers
Function
New
(code int, message string, statusCode int)
apps/api/pkg/errors/errors.go:17
↓ 8 callers
Function
SessionKey
SessionKey returns the Redis key for a session token.
apps/api/internal/middleware/auth.go:67
↓ 8 callers
Method
Update
Update edits an existing topic. PUT /api/topic/:tid
apps/api/internal/topic/handler/topic_handler.go:167
↓ 8 callers
Method
applyEditors
(ctx context.Context, req *http.Request, additionalEditors []RequestEditorFn)
apps/api/pkg/artifactclient/gen/artifact_client.gen.go:619
↓ 8 callers
Function
galgameNameFromWire
( g: WireGalgameName, fallback = '' )
apps/web/shared/utils/galgameStatus.ts:62
↓ 8 callers
Function
galgameStatusBadge
( status: number | undefined )
apps/web/shared/utils/galgameStatus.ts:32
↓ 8 callers
Function
kunFetch
( url: string, options?: Record<string, unknown> )
apps/web/app/utils/kunFetch.ts:246
↓ 8 callers
Function
num
(row: Record<string, unknown>, key: string)
apps/web/server/utils/kunSitemapSources.ts:164
↓ 8 callers
Function
truncate
────────────────────────────────────────── Helpers ──────────────────────────────────────────
apps/api/internal/galgame/service/comment_service.go:537
↓ 8 callers
Function
userBriefFromClient
userBriefFromClient maps a userclient.User to the UserBrief shape used across toolset DTOs. Centralized so every call site is consistent.
apps/api/internal/toolset/service/toolset_service.go:61
↓ 7 callers
Method
Create
Create — POST /doc/tag
apps/api/internal/doc/service/tag_service.go:31
↓ 7 callers
Function
SetContentImageCDNBase
SetContentImageCDNBase configures the CDN base for resolving /image/<hash> content refs. Call once at startup with cfg.GalgameWiki.ImageCDNBase.
apps/api/internal/infrastructure/markdown/markdown.go:97
↓ 7 callers
Method
Update
Update — PUT /doc/tag (moderator+ enforced at the route level).
apps/api/internal/doc/service/tag_service.go:52
↓ 7 callers
Method
Update
────────────────────────────────────────── Update — PUT /website-tag ──────────────────────────────────────────
apps/api/internal/website/service/tag_service.go:94
↓ 7 callers
Function
arrayDiffByKey
( oldArr: readonly T[] | undefined | null, newArr: readonly T[] | undefined | null, keyFn: (item: T) =>
apps/web/shared/utils/arrayDiffByKey.ts:30
↓ 7 callers
Function
getEffectiveBanner
( g?: BannerSource | null, opts?: { variant?: Extract<ImageVariant, 'mini'> } )
apps/web/shared/utils/getEffectiveBanner.ts:77
↓ 7 callers
Method
hideTarget
hideTarget reports whether the profile owner (userID) is banned. When true, every content tab must render nothing: the profile page itself already deg
apps/api/internal/user/service/user_content_service.go:40
↓ 7 callers
Function
isValidURL
(url: string)
apps/web/shared/utils/validate.ts:7
↓ 6 callers
Method
Create
Create inserts a new galgame_rating row.
apps/api/internal/galgame/repository/rating_repo.go:150
↓ 6 callers
Method
DB
()
apps/api/internal/toolset/repository/comment_repo.go:19
↓ 6 callers
Method
DB
()
apps/api/internal/doc/repository/tag_repo.go:17
↓ 6 callers
Method
Delete
Delete removes a comment by reference.
apps/api/internal/website/repository/comment_repo.go:116
↓ 6 callers
Function
Has
Has reports whether the claim set contains an exact role name.
apps/api/pkg/role/role.go:32
↓ 6 callers
Method
PostWithToken
PostWithToken performs a POST with Bearer token. contentType controls how body is forwarded: - "" (empty) → defaults to "application/json"; st
apps/api/internal/galgame/client/client.go:218
↓ 6 callers
Function
RenderInline
RenderInline renders message markdown to sanitized HTML — inline formatting plus images only. Output is safe to render with v-html.
apps/api/internal/infrastructure/markdown/inline.go:125
↓ 6 callers
Function
createUserPageNavItems
( userId: number, basePath: string, typesArray: readonly T[], config: Record<T, _NavItemData> )
apps/web/app/constants/user.ts:64
↓ 6 callers
Function
daysAgo
(n: number)
apps/web/shared/utils/time.spec.ts:26
↓ 6 callers
Function
emptyStrSliceIfNil
(s []string)
apps/api/internal/galgame/service/engine_service.go:102
↓ 6 callers
Function
pinCoverAtomic
( covers: readonly T[], targetHash: string )
apps/web/shared/utils/pinCoverAtomic.ts:27
↓ 5 callers
Method
Configured
Configured reports whether the client can talk to the artifact service.
apps/api/pkg/artifactclient/client.go:139
↓ 5 callers
Method
CreateTopicMessageWithContent
CreateTopicMessageWithContent is like CreateTopicMessage but stores a content preview. replyFloor/commentID deep-link the notification to a specific p
apps/api/internal/topic/service/interaction_helpers.go:50
↓ 5 callers
Method
Delete
────────────────────────────────────────── Delete — DELETE /toolset/:id ──────────────────────────────────────────
apps/api/internal/toolset/service/toolset_service.go:304
↓ 5 callers
Method
FindByID
FindByID returns the state row or sql.ErrNoRows if missing.
apps/api/internal/user/repository/state_repo.go:38
↓ 5 callers
Method
FindLikedSet
FindLikedSet returns the subset of commentIDs the user has liked. Anonymous (userID=0) or empty input → empty set without hitting DB. Used by GetComme
apps/api/internal/galgame/repository/comment_repo.go:25
↓ 5 callers
Method
Update
Update mutates an owner's collection (partial). The default collection can be renamed / re-described / re-privacied, but not deleted (see Delete).
apps/api/internal/galgame/service/collection_service.go:88
↓ 5 callers
Method
Update
────────────────────────────────────────── Update — PUT /toolset/:id ──────────────────────────────────────────
apps/api/internal/toolset/service/toolset_service.go:265
↓ 5 callers
Function
appendUniqueStr
(slice []string, val string)
apps/api/internal/galgame/service/resource_mapper.go:55
↓ 5 callers
Function
camelToSnakeCase
(str: string)
apps/web/shared/utils/format.ts:36
↓ 5 callers
Function
envOrDefaultInt
(key string, fallback int)
apps/api/pkg/config/config.go:256
↓ 5 callers
Method
fetchOwnerAndName
fetchOwnerAndName reads the galgame's owner user_id AND a display name from wiki in ONE request (0 / "" on any failure). The name becomes the notifica
apps/api/internal/galgame/service/galgame_service.go:345
↓ 5 callers
Function
formatDate
( time: Date | string | number, config?: { isShowYear?: boolean; isPrecise?: boolean } )
apps/web/shared/utils/time.ts:54
↓ 5 callers
Function
formatNumberWithCommas
(number: number)
apps/web/shared/utils/format.ts:28
↓ 5 callers
Function
getAssetsFile
(name: number)
apps/web/app/components/kun/setting-panel/components/getLoli.ts:4
↓ 5 callers
Function
isValidTimestamp
(timestamp: number)
apps/web/shared/utils/validate.ts:1
↓ 5 callers
Function
mapErr
mapErr turns a non-success artifact response into a sentinel (where callers branch) or a descriptive error.
apps/api/pkg/artifactclient/client.go:249
↓ 5 callers
Function
optionalString
(max: number, defaultValue = '')
apps/web/app/validations/doc.ts:23
↓ 5 callers
Function
requireEnv
(key string)
apps/api/pkg/config/config.go:241
↓ 5 callers
Function
toIso
(d: unknown)
apps/web/server/utils/kunSitemapSources.ts:59
↓ 5 callers
Function
tokenize
tokenize splits a keyword string into trimmed non-empty tokens. Returns an error if the result is empty.
apps/api/internal/search/service/search_service.go:38
next →
1–100 of 2,016, ranked by callers