mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2026-05-23 06:55:23 +00:00
Enhancement: unify text search to use tantivy (#12485)
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import unicodedata
|
||||
|
||||
|
||||
def ascii_fold(text: str) -> str:
|
||||
"""Normalize unicode text to ASCII equivalents for search consistency."""
|
||||
return unicodedata.normalize("NFD", text).encode("ascii", "ignore").decode()
|
||||
Reference in New Issue
Block a user