mirror of
https://github.com/rwinkhart/MUTN.git
synced 2026-08-28 04:46:41 -04:00
Do not re-upload entries when adding a blank note
This commit is contained in:
+2
-2
@@ -119,8 +119,8 @@ func editNote(baseNote []string) ([]string, bool) {
|
|||||||
// clamp trailing whitespace in each note line
|
// clamp trailing whitespace in each note line
|
||||||
core.ClampTrailingWhitespace(note)
|
core.ClampTrailingWhitespace(note)
|
||||||
|
|
||||||
// return the edited note if it is different from baseNote
|
// return the edited note if it is different from baseNote and is not empty
|
||||||
if !reflect.DeepEqual(note, baseNote) {
|
if !reflect.DeepEqual(note, baseNote) && len(note) > 0 {
|
||||||
return note, true
|
return note, true
|
||||||
} else {
|
} else {
|
||||||
return nil, false
|
return nil, false
|
||||||
|
|||||||
Reference in New Issue
Block a user