[fix] Add back toLowerCase to cleanAuthor/Title (required by other uses)

This commit is contained in:
mikiher 2023-10-03 19:43:37 +00:00
parent 46b0b3a6ef
commit 5d7c197c89

View File

@ -59,12 +59,12 @@ class BookFinder {
// Remove single quotes (i.e. "Ender's Game" becomes "Enders Game")
cleaned = cleaned.replace(/'/g, '')
return this.replaceAccentedChars(cleaned)
return this.replaceAccentedChars(cleaned).toLowerCase()
}
cleanAuthorForCompares(author) {
if (!author) return ''
return this.replaceAccentedChars(author)
return this.replaceAccentedChars(author).toLowerCase()
}
filterSearchResults(books, title, author, maxTitleDistance, maxAuthorDistance) {