farmerbb / Notepad

A simple, bare-bones, no-frills note taking app for Android.
Apache License 2.0
327 stars 99 forks source link

Export note to storage where note already exists #41

Open disrooter opened 5 years ago

disrooter commented 5 years ago

App version: 2.3.3

OS version: Android 8.1 (Lineage 15.1)

Expected behaviour: When exporting a note to a storage location where a file with the same name already exists, tapping the Save button should prompt the user with a dialog to confirm overwriting the existing file.

Actual behaviour: Despite the note having the same as an existing file, tapping the Save button proceeds to export the note without any prompts, appending a number to the filename (e.g. saved_note (1).txt; saved_note (2).txt; etc.). The only way to export a note to overwrite an existing file is to scroll and tap the filename from the file chooser/explorer list.

Steps to reproduce:

  1. Import text file from storage (e.g. example_note.txt)
  2. Edit note as desired (optional)
  3. Tap to export note
  4. Leave filename unchanged and tap Save button
  5. Browse storage location in a file explorer and notice that the file is not overwritten but is instead duplicated

Repeating steps 1 - 4 will therefore export the note multiple times. Is this the desired behaviour? It seems to perform contrary to most applications and operating systems.

timur-g commented 3 years ago

When there's some functionality, it's wrong to ask it to be changed. Rather, there should be an option what to do if notes are already saved in the same folder:

Would be very useful.