Skip to content

Commit

Permalink
bugs fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
RamanSharma100 committed Oct 17, 2022
1 parent fc7eb9d commit 604ed7d
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,8 @@ export default function Home({ profiles, filesData }) {
export async function getServerSideProps() {
// const profiles = await listReactFiles(__dirname + 'data/');
// console.log(__dirname);
const directoryPath =
process.env.NODE_ENV === 'production' ? '/shared/data' : '/shared/data';

const directoryPath = path.join(process.cwd(), './public/data');
const fileNames = [],
filesData = [];
const files = fs.readdirSync(directoryPath);
Expand All @@ -177,7 +176,7 @@ export async function getServerSideProps() {

return {
props: {
fileNames,
// fileNames,
filesData,
profiles: 'profiles'
}
Expand Down
File renamed without changes.
File renamed without changes.

1 comment on commit 604ed7d

@vercel
Copy link

@vercel vercel bot commented on 604ed7d Oct 17, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

gdsclpu-tree – ./

gdsclpu-tree.vercel.app
gdsclpu-tree-gdsclpu.vercel.app
gdsclpu-tree-git-main-gdsclpu.vercel.app

Please sign in to comment.