diff --git a/src/routes/location/[country]/[place].svelte b/src/routes/location/[country]/[place].svelte index c29dfdd..9227365 100644 --- a/src/routes/location/[country]/[place].svelte +++ b/src/routes/location/[country]/[place].svelte @@ -56,9 +56,10 @@ // Define dates $: latestPhoto = photos[0] - $: dateUpdatedFull = latestPhoto ? formatDate(latestPhoto.modified_on, 'FULL') : '' - $: dateUpdatedDatetime = latestPhoto ? formatDate(latestPhoto.modified_on, 'DATETIME') : '' - $: dateUpdatedRelative = latestPhoto ? relativeTime(latestPhoto.modified_on, 2592000000) : '' + $: latestPhotoModified = latestPhoto.modified_on.replace(' ', 'T') + $: dateUpdatedFull = latestPhoto ? formatDate(latestPhotoModified, 'FULL') : '' + $: dateUpdatedDatetime = latestPhoto ? formatDate(latestPhotoModified, 'DATETIME') : '' + $: dateUpdatedRelative = latestPhoto ? relativeTime(latestPhotoModified, 2592000000) : '' /*