From 5995730659aab159e13cd3eaa9e1c1dbb6ac30db Mon Sep 17 00:00:00 2001 From: Manav Rathi Date: Fri, 26 Jul 2024 14:54:51 +0530 Subject: [PATCH] Rearrange --- web/packages/new/photos/services/exif.ts | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/web/packages/new/photos/services/exif.ts b/web/packages/new/photos/services/exif.ts index dfe6cebe08..2a71ac4e84 100644 --- a/web/packages/new/photos/services/exif.ts +++ b/web/packages/new/photos/services/exif.ts @@ -86,6 +86,17 @@ export const parseExif = (tags: RawExifTags) => { return metadata; }; +/** + * Parse GPS location from the metadata embedded in the file. + */ +const parseLocation = (tags: RawExifTags) => { + const latitude = tags.gps?.Latitude; + const longitude = tags.gps?.Longitude; + return latitude !== undefined && longitude !== undefined + ? { latitude, longitude } + : undefined; +}; + /** * Parse a single "best" creation date for an image from the metadata embedded * in the file. @@ -364,17 +375,6 @@ const parseIPTCDate = ( return new Date(s); }; -/** - * Parse GPS location from the metadata embedded in the file. - */ -const parseLocation = (tags: RawExifTags) => { - const latitude = tags.gps?.Latitude; - const longitude = tags.gps?.Longitude; - return latitude !== undefined && longitude !== undefined - ? { latitude, longitude } - : undefined; -}; - /** * Parse the width and height of the image from the metadata embedded in the * file.