this post was submitted on 20 Nov 2024
865 points (97.5% liked)

Programmer Humor

19623 readers
3 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 1 year ago
MODERATORS
865
submitted 2 days ago* (last edited 2 days ago) by Maven to c/[email protected]
you are viewing a single comment's thread
view the rest of the comments
[–] Cethin 4 points 2 days ago (2 children)

They could have a warning though. I agree with you, but there are some easy ways to prevent this from happening. It just takes time to implement, and would be required in other places too. Is it worth the dev time? I doubt it.

[–] [email protected] 5 points 2 days ago

There is a warning. IIRC it says "are you sure you want to discard all changes? This action is unreverisble". In the context of version management. Creating a file is a change. And just below the button to discard all changes is the list of changes. In that list he could've seen 3000 changes of the type "file creation", when you discard a file creation, it means to undo the creation, which is a deletion.

The button days what is going to do. There is a warning about what it's going to do. And there is a list of the exact changes it's going to undo.

The only way to avoid this from happening is to not have the button exist. In that case, the users that actually want to discard all changes would be unable to do so.

[–] [email protected] 2 points 1 day ago

Right? "You are about to permanently delete 5,345 files, they will not be sent to the recycling bin, are you sure?"