mirror of
https://github.com/catdevnull/preciazo.git
synced 2024-11-26 03:26:19 +00:00
conseguir ultima imagen y nombre para pagina
This commit is contained in:
parent
930d1b109d
commit
a1faa4f73c
1 changed files with 1 additions and 1 deletions
|
@ -13,7 +13,7 @@ export const load: PageServerLoad = async ({ params }) => {
|
||||||
const res = await q;
|
const res = await q;
|
||||||
if (res.length === 0) return error(404, "Not Found");
|
if (res.length === 0) return error(404, "Not Found");
|
||||||
|
|
||||||
const meta = res.find((p) => p.name);
|
const meta = res.findLast((p) => p.name);
|
||||||
|
|
||||||
return { precios: res, meta };
|
return { precios: res, meta };
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue