From 342c57532e92f1beab8e1b1617ad07cdf118f96e Mon Sep 17 00:00:00 2001 From: Ryan Cheung Date: Thu, 29 Jun 2023 21:16:25 -0700 Subject: [PATCH] Update location parsing --- pages/api/poll/foursquare.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pages/api/poll/foursquare.ts b/pages/api/poll/foursquare.ts index 7cac04a..8eae45d 100644 --- a/pages/api/poll/foursquare.ts +++ b/pages/api/poll/foursquare.ts @@ -78,7 +78,7 @@ async function post(req: NextApiRequest, res: NextApiResponse) { if (photo.venue) { const { city, state, country } = photo.venue.location const location = - city && state + city && state && city !== state ? `${city}, ${state}` : city && country ? `${city}, ${country}`