mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-10-31 13:01:31 +08:00 
			
		
		
		
	don't display similar notes under search
This commit is contained in:
		
							parent
							
								
									75c3bd8ae3
								
							
						
					
					
						commit
						95760f1d28
					
				| @ -41,7 +41,9 @@ const TPL = ` | ||||
| 
 | ||||
| export default class SimilarNotesWidget extends TabAwareWidget { | ||||
|     isEnabled() { | ||||
|         return super.isEnabled() && !this.note.hasLabel('similarNotesWidgetDisabled'); | ||||
|         return super.isEnabled() | ||||
|             && this.note.type !== 'search' | ||||
|             && !this.note.hasLabel('similarNotesWidgetDisabled'); | ||||
|     } | ||||
| 
 | ||||
|     doRender() { | ||||
|  | ||||
| @ -566,7 +566,7 @@ class ConsistencyChecks { | ||||
|     } | ||||
| 
 | ||||
|     runDbDiagnostics() { | ||||
|         function getTableCount(tableName) { | ||||
|         function getTableRowCount(tableName) { | ||||
|             const count = sql.getValue(`SELECT COUNT(1) FROM ${tableName}`); | ||||
| 
 | ||||
|             return `${tableName}: ${count}`; | ||||
| @ -574,7 +574,7 @@ class ConsistencyChecks { | ||||
| 
 | ||||
|         const tables = [ "notes", "note_revisions", "branches", "attributes", "api_tokens" ]; | ||||
| 
 | ||||
|         log.info("Table counts: " + tables.map(tableName => getTableCount(tableName)).join(", ")); | ||||
|         log.info("Table counts: " + tables.map(tableName => getTableRowCount(tableName)).join(", ")); | ||||
|     } | ||||
| 
 | ||||
|     async runChecks() { | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 zadam
						zadam