diff --git a/pages/index.js b/pages/index.js index 6006859..d1bff46 100644 --- a/pages/index.js +++ b/pages/index.js @@ -160,10 +160,9 @@ export default function Home({ profiles, filesData }) { export async function getServerSideProps() { // const profiles = await listReactFiles(__dirname + 'data/'); // console.log(__dirname); - const directoryPath = path.join( - getConfig().serverRuntimeConfig.PROJECT_ROOT, - process.env.NODE_ENV === 'production' ? '/shared/data' : '/shared/data' - ); + const directoryPath = + process.env.NODE_ENV === 'production' ? '/shared/data' : '/shared/data'; + const fileNames = [], filesData = []; const files = fs.readdirSync(directoryPath);