Skip to content

Commit

Permalink
Strip invalid chars
Browse files Browse the repository at this point in the history
Signed-off-by: Glenn Lewis <6598971+gmlewis@users.noreply.github.com>
  • Loading branch information
gmlewis committed Mar 26, 2023
1 parent b0f62ea commit 238ec7c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/components/SearchBooks.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ const books = ref([])
const shortcut = ref('')
const newSearch = () => {
name.value = name.value.replace(/[^a-z]+/ig, '')
const lookup = booksByName[name.value.toLowerCase()]
if (!lookup) {
books.value = []
Expand Down

0 comments on commit 238ec7c

Please sign in to comment.