Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
bo-lu committed Nov 1, 2024
1 parent 2249df4 commit 2b0c1f1
Showing 1 changed file with 13 additions and 12 deletions.
25 changes: 13 additions & 12 deletions src/components/search/metadatapage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -449,18 +449,19 @@ const MetaDataPage = (props) => {
const desc = option.description[language].split(";");
return { name: option.name[language], type: desc[0], format: desc[1], language: t(`page.${desc[2].toLowerCase().replace(',', '')}`), url: option.url };
});
const imageUrls = res.options.filter(o =>
o.url && o.url !== null &&
o.description && o.description.en &&
(
o.description.en.toLowerCase().indexOf("data;tiff;") >= 0 ||
o.description.en.toLowerCase().indexOf("image/tiff") >= 0 ||
o.description.en.toLowerCase().indexOf("thumbnail;png") >= 0 ||
o.description.en.toLowerCase().indexOf("image/png") >= 0 ||
o.description.en.toLowerCase().indexOf("thumbnail;jpeg") >= 0 ||
o.description.en.toLowerCase().indexOf("image/jpeg") >= 0 ||
o.description.en.toLowerCase().indexOf("application/geotiff") >= 0
)

const imageUrls = formattedOption.filter(o =>
o.url && o.url !== null &&
o.description && o.description.en &&
(
o.description.en.toLowerCase().indexOf("data;tiff;") >= 0 ||
o.description.en.toLowerCase().indexOf("image/tiff") >= 0 ||
o.description.en.toLowerCase().indexOf("thumbnail;png") >= 0 ||
o.description.en.toLowerCase().indexOf("image/png") >= 0 ||
o.description.en.toLowerCase().indexOf("thumbnail;jpeg") >= 0 ||
o.description.en.toLowerCase().indexOf("image/jpeg") >= 0 ||
o.description.en.toLowerCase().indexOf("application/geotiff") >= 0
)
);
let url;
const isSentinel1=imageUrls.length>0 && result.sourceSystemName==='ccmeo-eodms' && result.eoCollection==='sentinel-1' && thumbnailConfig['eodms_use_image'];
Expand Down

0 comments on commit 2b0c1f1

Please sign in to comment.