Skip to content

Commit

Permalink
Merge pull request #73 from glmxndr/master
Browse files Browse the repository at this point in the history
Allow for query parameters already present in the items URL
  • Loading branch information
m-mohr authored Apr 11, 2021
2 parents 2bcff85 + 0f9fd35 commit 93aae66
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/components/Catalog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -373,8 +373,9 @@ export default {
}
try {
let sep = externalItemsLink.href.includes('?') ? '&' : '?';
const rsp = await fetchUri(
`${externalItemsLink.href}?page=${this.currentItemPage}`
`${externalItemsLink.href}${sep}page=${this.currentItemPage}`
);
if (!rsp.ok) {
Expand Down Expand Up @@ -404,7 +405,7 @@ export default {
return items.features.map((item, idx) => ({
item,
to: `/item${p}/${this.slugify(
`${externalItemsLink.href}?page=${this.currentItemPage}#${idx}`
`${externalItemsLink.href}${sep}page=${this.currentItemPage}#${idx}`
)}`,
title: item.properties.title || item.id,
dateAcquired: item.properties.datetime
Expand Down

0 comments on commit 93aae66

Please sign in to comment.