mirror of
https://github.com/moku-project/Moku.git
synced 2026-06-13 09:19:56 -05:00
Chore: Fix Nix Build (Improper)
This commit is contained in:
@@ -14,6 +14,8 @@ import type {
|
||||
SetSocksProxyInput,
|
||||
SetFlareSolverrInput,
|
||||
TrackRecordPatch,
|
||||
AboutServer,
|
||||
AboutWebUI,
|
||||
} from '$lib/server-adapters/types'
|
||||
import type { DownloadStatus } from '$lib/types/api'
|
||||
import type { Manga, Chapter, Extension, Source, Tracker, TrackRecord, Category } from '$lib/types'
|
||||
@@ -84,6 +86,10 @@ import {
|
||||
TRACK_PROGRESS,
|
||||
UPDATE_TRACK,
|
||||
} from './tracking'
|
||||
import {
|
||||
GET_ABOUT_SERVER,
|
||||
GET_ABOUT_WEBUI,
|
||||
} from './meta'
|
||||
import {
|
||||
type GQLResponse,
|
||||
mapManga,
|
||||
@@ -205,6 +211,16 @@ export class SuwayomiAdapter implements ServerAdapter {
|
||||
return json.data
|
||||
}
|
||||
|
||||
async getAboutServer(): Promise<AboutServer> {
|
||||
const data = await this.gql<{ aboutServer: AboutServer }>(GET_ABOUT_SERVER)
|
||||
return data.aboutServer
|
||||
}
|
||||
|
||||
async getAboutWebUI(): Promise<AboutWebUI> {
|
||||
const data = await this.gql<{ aboutWebUI: AboutWebUI }>(GET_ABOUT_WEBUI)
|
||||
return data.aboutWebUI
|
||||
}
|
||||
|
||||
async getManga(id: string): Promise<Manga> {
|
||||
const data = await this.gql<{ manga: Record<string, unknown> }>(GET_MANGA, { id: Number(id) })
|
||||
return mapManga(data.manga)
|
||||
|
||||
Reference in New Issue
Block a user