-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
merch gallery api files #7
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
routes/merchgallery.js
Outdated
|
||
router.get("/merchgallery", async (req, res) => { | ||
//show the orign of the request | ||
console.log("client IP: ", req.ip, ", connects to merch endpoint of TechStart server"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should be logging the user's IP here
routes/merchgallery.js
Outdated
const retrieveAlbum = async () => { | ||
try { | ||
// URL for the Google Photos album | ||
const albumUrl =process.env.GOOGLE_MERCH_PHOTOS_URL; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a missing space between "=" and "process"
const albumUrl = process.env.GOOGLE_MERCH_PHOTOS_URL;
} | ||
} catch (error) { | ||
console.error("Error fetching album:", error); | ||
throw new Error("Error fetching album"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you intentially throwing an error inside the catch block?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed on Brian's comments, otherwise LGTM
Signed-off-by: Sahitiakella <[email protected]>
No description provided.