mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 19:49:01 +01:00 
			
		
		
		
	convert   into whitespace also for large notes
This commit is contained in:
		
							parent
							
								
									a266d6a3d5
								
							
						
					
					
						commit
						577dc95ab8
					
				| @ -42,11 +42,11 @@ class NoteContentProtectedFulltextExp extends Expression { | ||||
| 
 | ||||
|             content = content.toLowerCase(); | ||||
| 
 | ||||
|             if (type === 'text' | ||||
|                 && mime === 'text/html' | ||||
|                 && content.length < 20000 // striptags is very slow for large notes
 | ||||
|             ) { | ||||
|                 content = striptags(content); | ||||
|             if (type === 'text' && mime === 'text/html') { | ||||
|                 if (content.length < 20000) { // striptags is slow for very large notes
 | ||||
|                     content = striptags(content); | ||||
|                 } | ||||
| 
 | ||||
|                 content = content.replace(/ /g, ' '); | ||||
|             } | ||||
| 
 | ||||
|  | ||||
| @ -28,11 +28,11 @@ class NoteContentUnprotectedFulltextExp extends Expression { | ||||
| 
 | ||||
|             content = content.toString().toLowerCase(); | ||||
| 
 | ||||
|             if (type === 'text' | ||||
|                 && mime === 'text/html' | ||||
|                 && content.length < 20000 // striptags is very slow for large notes
 | ||||
|             ) { | ||||
|                 content = striptags(content); | ||||
|             if (type === 'text' && mime === 'text/html') { | ||||
|                 if (content.length < 20000) { // striptags is slow for very large notes
 | ||||
|                     content = striptags(content); | ||||
|                 } | ||||
| 
 | ||||
|                 content = content.replace(/ /g, ' '); | ||||
|             } | ||||
| 
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 zadam
						zadam