Skip to content
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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

merch gallery api files #7

wants to merge 2 commits into from

Conversation

Sahitiakella
Copy link
Collaborator

No description provided.

Copy link

vercel bot commented Mar 23, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
tsu-server ✅ Ready (Inspect) Visit Preview 💬 Add feedback Apr 18, 2024 2:31am


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");
Copy link
Member

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

const retrieveAlbum = async () => {
try {
// URL for the Google Photos album
const albumUrl =process.env.GOOGLE_MERCH_PHOTOS_URL;
Copy link
Member

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");
Copy link
Member

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?

Copy link
Collaborator

@Anidion Anidion left a 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]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants