capture the right value of the rss feed url in search string

This commit is contained in:
Hongbo Wu
2023-12-06 10:46:15 +08:00
parent 9b210d6ac0
commit c8bd953cf3
2 changed files with 1 additions and 14 deletions

View File

@ -6,7 +6,7 @@ export const parseSearchQuery = (query: string): LiqeQuery => {
.replace('in:subscription', 'has:subscriptions') // compatibility with old search
.replace('in:library', 'no:subscription') // compatibility with old search
// wrap the value behind colon in quotes if it's not already
.replace(/(\w+):([^"\s]+)/g, '$1:"$2"')
.replace(/(\w+):("([^"]+)"|([^"\s]+))/g, '$1:"$3$4"')
return parse(searchQuery)
}