android icon indicating copy to clipboard operation
android copied to clipboard

Option to delete messages immediately

Open hydrargyrum opened this issue 1 year ago • 2 comments

When deleting a message in the app, there's a kind of toast for a few seconds to "undo" the deletion. From my tests, actually the message is not deleted until the toast disappears. It's like this toast is a confirmation prompt in disguise. You would think the deletion is triggered and the toast appears when the server replied 200 to deletion, but no, the toast appears, then when it disappears, the deletion request is sent and you don't know when it's received.

I often delete a message and quit the app right after the toast appears, but then the message is not deleted! When I open the app, the message is still there. Instead, I have to wait several seconds for the toast to disappear, and then maybe the message is deleted, so only then I can quit the app and it won't be back when I open the app. This is awful.

Either:

  • make that fake toast not lie by telling "message deleted", when the message is not deleted yet: put something like "message will be deleted when toast disappears", so the user does not quit the app because then the deletion will not be effective
  • have an option to only show the toast when message is really deleted (server replied 200)
  • have an option not to show any toast at all and delete the message straight away

hydrargyrum avatar Jun 16 '23 09:06 hydrargyrum

Technically you are right. The HTTP request for deleting the message is not executed immediately.
Because if you would delete it immediately, you would have no way to restore that message because it's already deleted on the client and server side.

Maybe slightly relabeling the toast would be the best way to solve this.

cyb3rko avatar Jun 16 '23 14:06 cyb3rko

Maybe slightly relabeling the toast would be the best way to solve this.

Okay for me, but let me advocate for the other options again ;)

Because if you would delete it immediately, you would have no way to restore that message because it's already deleted on the client and server side.

On Android, for the standard notifications in the menu you drag from the top, if you slide a notification, you can't "undelete" it. I can understand if you want to keep the feature to "undelete" gotify's notifications, but I'm personally not interested (and I think I'm probably not alone) in such a feature, and I'd like to (optionally, with a new setting in the app settings if you prefer) not have to wait several seconds doing nothing in front of the app before I can finally do something else.

hydrargyrum avatar Jun 16 '23 19:06 hydrargyrum