Skip to content

Commit

Permalink
Reorganise routing and make params better named
Browse files Browse the repository at this point in the history
  • Loading branch information
aurora-dot committed May 22, 2024
1 parent 2979cea commit 237b975
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ export function updateMetadata(product: ProductType) {
export default async function Page({
params,
}: {
params: { company: string; slug: string };
params: { company_slug: string; product_slug: string };
}) {
let product: ProductType | null = null;
try {
product = await fetchProductData(params.company, params.slug);
product = await fetchProductData(params.company_slug, params.product_slug);
} catch (error) {
if (error instanceof TypeError) notFound();
else console.log(error);
Expand Down

0 comments on commit 237b975

Please sign in to comment.