1
0
mirror of https://github.com/axllent/mailpit.git synced 2025-08-15 20:13:16 +02:00

Fix: Better regexp to detect tags in search

This commit is contained in:
Ralph Slooten
2024-08-04 17:07:53 +12:00
parent 22693f727f
commit 4716c18d5f

View File

@@ -6,8 +6,6 @@ import { pagination } from '../stores/pagination'
export default {
mixins: [CommonMixins],
emits: ['loadMessages'],
data() {
return {
mailbox,
@@ -24,7 +22,7 @@ export default {
return false
}
let re = new RegExp(`(^|\\s)tag:"?${tag}"?($|\\s)`, 'i')
let re = new RegExp(`\\btag:("${tag}"|${tag}\\b)`, 'i')
return query.match(re)
},