Skip to content

Commit

Permalink
manual: Change structure & Refactor to make code up to date
Browse files Browse the repository at this point in the history
  • Loading branch information
hbjORbj committed Jan 5, 2024
1 parent 88ea1e8 commit 5daf52d
Showing 1 changed file with 3 additions and 18 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import OldPage from "@pages/insights/index";
import LegacyPage from "@pages/insights/index";
import { _generateMetadata } from "app/_utils";
import { headers } from "next/headers";
import { WithLayout } from "app/layoutHOC";
import { notFound } from "next/navigation";

import { getLayout } from "@calcom/features/MainLayoutAppDir";
import { getFeatureFlagMap } from "@calcom/features/flags/server/utils";

import PageWrapper from "@components/PageWrapperAppDir";

export const generateMetadata = async () =>
await _generateMetadata(
() => "Insights",
Expand All @@ -25,17 +23,4 @@ async function getData() {
return {};
}

const Page = async () => {
const h = headers();
const nonce = h.get("x-nonce") ?? undefined;

await getData();

return (
<PageWrapper getLayout={getLayout} requiresLicense={false} nonce={nonce} themeBasis={null}>
<OldPage />
</PageWrapper>
);
};

export default Page;
export default WithLayout({ getLayout, getData, Page: LegacyPage });

0 comments on commit 5daf52d

Please sign in to comment.