Fix refreshing manga during migration search

This commit is contained in:
schroda
2026-04-23 19:34:43 +02:00
parent 2ae613885d
commit 0ed2e7c193
5 changed files with 67 additions and 14 deletions

View File

@@ -212,6 +212,8 @@ import type {
DeleteChapterMetasInput,
SetCategoryMetasInput,
DeleteCategoryMetasInput,
RefreshMangaMutation,
RefreshMangaMutationVariables,
} from '@/lib/graphql/generated/graphql.ts';
import {
CategoryOrderBy,
@@ -240,6 +242,7 @@ import { GET_MIGRATABLE_SOURCES, GET_SOURCES_LIST } from '@/lib/graphql/source/S
import {
GET_MANGA_FETCH,
GET_MANGA_TO_MIGRATE_TO_FETCH,
REFRESH_MANGA,
UPDATE_MANGA,
UPDATE_MANGA_CATEGORIES,
UPDATE_MANGA_METADATA,
@@ -2218,6 +2221,20 @@ export class RequestManager {
);
}
public refreshManga(
mangaId: number | string,
options?: MutationOptions<RefreshMangaMutation, RefreshMangaMutationVariables>,
): AbortableApolloMutationResponse<RefreshMangaMutation> {
return this.doRequest<RefreshMangaMutation, RefreshMangaMutationVariables>(
GQLMethod.MUTATION,
REFRESH_MANGA,
{
id: Number(mangaId),
},
{ refetchQueries: [GET_CHAPTERS_MANGA], ...options },
);
}
public getMangaToMigrateToFetch(
mangaId: number | string,
{