Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion web/client/utils/CatalogUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ const getWMSBBox = (record) => {
}
return bbox;
};
const getBaseCatalogUrl = (url) => {
return url && url.replace(/\/csw$/, "/");
};

const getWMTSBBox = (record) => {
let layer = record;
Expand Down Expand Up @@ -115,7 +118,7 @@ const converters = {
if (thumbURL) {
let absolute = (thumbURL.indexOf("http") === 0);
if (!absolute) {
thumbURL = options.catalogURL + "/" + thumbURL;
thumbURL = (getBaseCatalogUrl(options.url) || "") + thumbURL;
}
}
// create the references array (now only wms is supported)
Expand Down