Просмотр исходного кода

Revert "Redirect to '/' if already installed"

This reverts commit 6154c5fdb5ca3a72ee874a6fe7983202c6d159dc.
Shun Miyazawa 3 лет назад
Родитель
Сommit
276a04ee33
1 измененных файлов с 0 добавлено и 12 удалено
  1. 0 12
      packages/app/src/pages/installer.page.tsx

+ 0 - 12
packages/app/src/pages/installer.page.tsx

@@ -7,7 +7,6 @@ import {
 import { serverSideTranslations } from 'next-i18next/serverSideTranslations';
 
 import { NoLoginLayout } from '~/components/Layout/NoLoginLayout';
-import { CrowiRequest } from '~/interfaces/crowi-request';
 
 import InstallerForm from '../components/InstallerForm';
 import {
@@ -54,17 +53,6 @@ const InstallerPage: NextPage<Props> = (props: Props) => {
 export const getServerSideProps: GetServerSideProps = async(context: GetServerSidePropsContext) => {
   const result = await getServerSideCommonProps(context);
 
-  const req = context.req as CrowiRequest;
-  const isInstalled = req.crowi.configManager.getConfig('crowi', 'app:installed');
-  if (isInstalled) {
-    return {
-      redirect: {
-        permanent: false,
-        destination: '/',
-      },
-    };
-  }
-
   // check for presence
   // see: https://github.com/vercel/next.js/issues/19271#issuecomment-730006862
   if (!('props' in result)) {