mirror of
https://github.com/SimpleMobileTools/Simple-Notes.git
synced 2025-06-05 17:00:23 +02:00
handle note updating and inserting
This commit is contained in:
@ -188,8 +188,9 @@ class NoteFragment : androidx.fragment.app.Fragment() {
|
||||
|
||||
private fun saveNoteValue(note: Note) {
|
||||
if (note.path.isEmpty()) {
|
||||
db.updateNote(note)
|
||||
(activity as MainActivity).noteSavedSuccessfully(note.title)
|
||||
NotesHelper(activity!!).insertOrUpdateNote(note) {
|
||||
(activity as MainActivity).noteSavedSuccessfully(note.title)
|
||||
}
|
||||
} else {
|
||||
val currentText = getCurrentNoteViewText()
|
||||
if (currentText != null) {
|
||||
|
Reference in New Issue
Block a user