mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 10:26:08 +01:00 
			
		
		
		
	small fixes
This commit is contained in:
		| @@ -63,8 +63,6 @@ class Attribute extends AbstractEntity { | |||||||
|     } |     } | ||||||
|  |  | ||||||
|     init() { |     init() { | ||||||
|         this.validate(); |  | ||||||
|  |  | ||||||
|         if (this.attributeId) { |         if (this.attributeId) { | ||||||
|             this.becca.attributes[this.attributeId] = this; |             this.becca.attributes[this.attributeId] = this; | ||||||
|         } |         } | ||||||
|   | |||||||
| @@ -49,7 +49,7 @@ function updateNoteAttribute(req) { | |||||||
|         } |         } | ||||||
|     } |     } | ||||||
|     else { |     else { | ||||||
|         if (body.type === 'relation' && !body.value.trim()) { |         if (body.type === 'relation' && !body.value?.trim()) { | ||||||
|             return {}; |             return {}; | ||||||
|         } |         } | ||||||
|  |  | ||||||
| @@ -68,6 +68,8 @@ function updateNoteAttribute(req) { | |||||||
|         attribute.markAsDeleted(); |         attribute.markAsDeleted(); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|  |     console.log(attribute); | ||||||
|  |  | ||||||
|     attribute.save(); |     attribute.save(); | ||||||
|  |  | ||||||
|     return { |     return { | ||||||
|   | |||||||
| @@ -209,7 +209,7 @@ function createLauncher({parentNoteId, launcherType, id}) { | |||||||
| function resetLauncher(noteId) { | function resetLauncher(noteId) { | ||||||
|     const note = becca.getNote(noteId); |     const note = becca.getNote(noteId); | ||||||
|  |  | ||||||
|     if (note.isLauncherConfig()) { |     if (note.isLaunchBarConfig()) { | ||||||
|         if (note) { |         if (note) { | ||||||
|             if (noteId === '_lbRoot') { |             if (noteId === '_lbRoot') { | ||||||
|                 // deleting hoisted notes are not allowed, so we just reset the children |                 // deleting hoisted notes are not allowed, so we just reset the children | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user