mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 10:26:08 +01:00 
			
		
		
		
	removed unnecessary async/awaits
This commit is contained in:
		| @@ -456,7 +456,7 @@ export default class NoteTreeWidget extends TabAwareWidget { | |||||||
|         const title = (branch.prefix ? (branch.prefix + " - ") : "") + note.title; |         const title = (branch.prefix ? (branch.prefix + " - ") : "") + note.title; | ||||||
|         const hoistedNoteId = hoistedNoteService.getHoistedNoteId(); |         const hoistedNoteId = hoistedNoteService.getHoistedNoteId(); | ||||||
|  |  | ||||||
|         const isFolder = await this.isFolder(note); |         const isFolder = this.isFolder(note); | ||||||
|  |  | ||||||
|         const node = { |         const node = { | ||||||
|             noteId: note.noteId, |             noteId: note.noteId, | ||||||
| @@ -481,7 +481,7 @@ export default class NoteTreeWidget extends TabAwareWidget { | |||||||
|         return node; |         return node; | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     async isFolder(note) { |     isFolder(note) { | ||||||
|         if (note.type === 'search') { |         if (note.type === 'search') { | ||||||
|             return true; |             return true; | ||||||
|         } |         } | ||||||
| @@ -717,11 +717,11 @@ export default class NoteTreeWidget extends TabAwareWidget { | |||||||
|         return this.getNodeFromPath(notePath, true, expandOpts); |         return this.getNodeFromPath(notePath, true, expandOpts); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     async updateNode(node) { |     updateNode(node) { | ||||||
|         const note = treeCache.getNoteFromCache(node.data.noteId); |         const note = treeCache.getNoteFromCache(node.data.noteId); | ||||||
|         const branch = treeCache.getBranch(node.data.branchId); |         const branch = treeCache.getBranch(node.data.branchId); | ||||||
|  |  | ||||||
|         const isFolder = await this.isFolder(note); |         const isFolder = this.isFolder(note); | ||||||
|  |  | ||||||
|         node.data.isProtected = note.isProtected; |         node.data.isProtected = note.isProtected; | ||||||
|         node.data.noteType = note.type; |         node.data.noteType = note.type; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user