Skip to content

Commit

Permalink
Merge pull request #17 from malteish/move_leaves
Browse files Browse the repository at this point in the history
Move leaves
  • Loading branch information
malteish authored Mar 5, 2023
2 parents b70be4c + a9d9b14 commit 0f2fc3c
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions webApp/pages/api/claim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,25 @@ export default function handler(

console.log("fullPath: ", fullPath);

if (!existsSync(path.join(process.cwd(), "private"))) {
console.log("private folder does not exist");
} else {
console.log("private folder exists");
}

// check public folder
if (!existsSync(path.join(process.cwd(), "public"))) {
console.log("public folder does not exist");
} else {
console.log("public folder exists");
}

if (!existsSync(fullPath)) {
console.log("file does not exist");
} else {
console.log("file exists");
}

let addressesArray = readFileSync(fullPath).toString().split(",");
if (!addressesArray.includes(address)) {
return res
Expand Down

1 comment on commit 0f2fc3c

@vercel
Copy link

@vercel vercel bot commented on 0f2fc3c Mar 5, 2023

Choose a reason for hiding this comment

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

Please sign in to comment.