mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-07-11 04:54:20 +08:00
moveNote: Do nothing if dest is the current folder
This commit is contained in:
@ -160,6 +160,9 @@ class StateContainerState extends State<StateContainer> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void moveNote(Note note, NotesFolder destFolder) {
|
void moveNote(Note note, NotesFolder destFolder) {
|
||||||
|
if (destFolder.folderPath == note.parent.folderPath) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
var oldNotePath = note.filePath;
|
var oldNotePath = note.filePath;
|
||||||
note.move(destFolder);
|
note.move(destFolder);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user