Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Use entryway for labeler getServices (#3256)

authored by

Paul Frazee and committed by
GitHub
1b10c7bc 20d463ff

+4 -4
+4 -4
src/state/queries/labeler.ts
··· 4 4 5 5 import {getAgent} from '#/state/session' 6 6 import {preferencesQueryKey} from '#/state/queries/preferences' 7 - import {STALE, PUBLIC_BSKY_AGENT} from '#/state/queries' 7 + import {STALE} from '#/state/queries' 8 8 9 9 export const labelerInfoQueryKey = (did: string) => ['labeler-info', did] 10 10 export const labelersInfoQueryKey = (dids: string[]) => [ ··· 27 27 enabled: !!did && enabled !== false, 28 28 queryKey: labelerInfoQueryKey(did as string), 29 29 queryFn: async () => { 30 - const res = await PUBLIC_BSKY_AGENT.app.bsky.labeler.getServices({ 30 + const res = await getAgent().app.bsky.labeler.getServices({ 31 31 dids: [did as string], 32 32 detailed: true, 33 33 }) ··· 41 41 enabled: !!dids.length, 42 42 queryKey: labelersInfoQueryKey(dids), 43 43 queryFn: async () => { 44 - const res = await PUBLIC_BSKY_AGENT.app.bsky.labeler.getServices({dids}) 44 + const res = await getAgent().app.bsky.labeler.getServices({dids}) 45 45 return res.data.views as AppBskyLabelerDefs.LabelerView[] 46 46 }, 47 47 }) ··· 54 54 gcTime: 1000 * 60 * 60 * 6, // 6 hours 55 55 staleTime: STALE.MINUTES.ONE, 56 56 queryFn: async () => { 57 - const res = await PUBLIC_BSKY_AGENT.app.bsky.labeler.getServices({ 57 + const res = await getAgent().app.bsky.labeler.getServices({ 58 58 dids, 59 59 detailed: true, 60 60 })