feat: ajout d'une route GetMangaByIdHandler.php et fix de la SearchBar.vue
This commit is contained in:
parent
ed0a075a6c
commit
d9e935f7de
@@ -24,7 +24,7 @@ export class ApiMangaRepository {
|
||||
|
||||
async getMangaById(id) {
|
||||
try {
|
||||
const response = await fetch(`/api/mangas/${id}`);
|
||||
const response = await fetch(`/api/mangas/by-id/${id}`);
|
||||
if (!response.ok) {
|
||||
throw new Error('Failed to fetch manga details');
|
||||
}
|
||||
@@ -64,7 +64,7 @@ export class ApiMangaRepository {
|
||||
|
||||
async getMangaBySlug(slug) {
|
||||
try {
|
||||
const response = await fetch(`/api/mangas/${slug}`);
|
||||
const response = await fetch(`/api/mangas/by-slug/${slug}`);
|
||||
if (!response.ok) {
|
||||
throw new Error('Failed to fetch manga details');
|
||||
}
|
||||
@@ -87,4 +87,4 @@ export class ApiMangaRepository {
|
||||
throw error;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user