mirror of
https://github.com/zadam/trilium.git
synced 2024-09-20 23:55:59 +08:00
don't strip tags for very large text notes, #1500
This commit is contained in:
parent
749b6cb57e
commit
a266d6a3d5
|
@ -44,7 +44,7 @@ class NoteContentProtectedFulltextExp extends Expression {
|
|||
|
||||
if (type === 'text'
|
||||
&& mime === 'text/html'
|
||||
&& content.length < 50000 // striptags is very slow for large notes
|
||||
&& content.length < 20000 // striptags is very slow for large notes
|
||||
) {
|
||||
content = striptags(content);
|
||||
content = content.replace(/ /g, ' ');
|
||||
|
|
|
@ -30,7 +30,7 @@ class NoteContentUnprotectedFulltextExp extends Expression {
|
|||
|
||||
if (type === 'text'
|
||||
&& mime === 'text/html'
|
||||
&& content.length < 50000 // striptags is very slow for large notes
|
||||
&& content.length < 20000 // striptags is very slow for large notes
|
||||
) {
|
||||
content = striptags(content);
|
||||
content = content.replace(/ /g, ' ');
|
||||
|
|
Loading…
Reference in a new issue