Skip to content

Commit

Permalink
safeguard q parameter in template (#1037)
Browse files Browse the repository at this point in the history
  • Loading branch information
tomkralidis committed Nov 2, 2024
1 parent 9165e37 commit 26d43a1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pycsw/ogc/api/templates/items.html
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
<div class="input-group mb-3">
<input type="text" class="form-control" name="q" placeholder="Search" id="tbq" value="">
<script>
$('#tbq').val(decodeURIComponent("{{ attrs['q'].replace('+',' ') }}"))
$('#tbq').val(decodeURIComponent("{{ attrs.get('q', '').replace('+',' ') }}"))
</script>
<input class="btn btn-outline-secondary" type="submit" value="Search"></input>
</div>
Expand Down

0 comments on commit 26d43a1

Please sign in to comment.