fix: resolve RSC plain object leak in AdWrappers
This commit is contained in:
parent
31bf643d3b
commit
447569569b
@ -81,6 +81,8 @@ async function fetchHomeData(page: number = 1, isAdmin: boolean = false, adminMo
|
|||||||
...p,
|
...p,
|
||||||
resolved_media: mediaMap.get(p.imagen_destacada_id as string)
|
resolved_media: mediaMap.get(p.imagen_destacada_id as string)
|
||||||
})));
|
})));
|
||||||
|
} else {
|
||||||
|
posts = JSON.parse(JSON.stringify(posts));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -51,7 +51,7 @@ export async function GlobalTopBanner() {
|
|||||||
|
|
||||||
if (banners.length === 0) return null;
|
if (banners.length === 0) return null;
|
||||||
|
|
||||||
return <TopBanner initialBanners={banners} rotationSeconds={settings.rotation_seconds} />
|
return <TopBanner initialBanners={JSON.parse(JSON.stringify(banners))} rotationSeconds={settings.rotation_seconds} />
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function GlobalSidebar() {
|
export async function GlobalSidebar() {
|
||||||
@ -109,7 +109,7 @@ export async function GlobalSidebar() {
|
|||||||
|
|
||||||
if (Object.keys(groupedAds).length === 0) return null;
|
if (Object.keys(groupedAds).length === 0) return null;
|
||||||
|
|
||||||
return <ClientSidebars groupedAds={groupedAds} rotationSeconds={settings.rotation_seconds} />
|
return <ClientSidebars groupedAds={JSON.parse(JSON.stringify(groupedAds))} rotationSeconds={settings.rotation_seconds} />
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function hasSidebarContent(): Promise<boolean> {
|
export async function hasSidebarContent(): Promise<boolean> {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user