Skip to content

Commit

Permalink
safeguard q parameter in template (#1037) (#1038)
Browse files Browse the repository at this point in the history
  • Loading branch information
tomkralidis authored Nov 2, 2024
1 parent 9165e37 commit d4fa9aa
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 d4fa9aa

Please sign in to comment.