Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delete all local files on account removal #1109

Merged
merged 2 commits into from
Jul 16, 2017

Conversation

tobiasKaminsky
Copy link
Member

@tobiasKaminsky tobiasKaminsky commented Jun 23, 2017

Ref: #627

To discuss:

  • how to prevent that an user clicks on account removal and then immediately kills the app to prevent file deletion

@AndyScherzinger
Copy link
Member

you can't I#d say, the user could also copy all the files manually and then delete the account.
Else you would nbeed to do cyclic checks for account folders for which there is no account in the database...

@tobiasKaminsky
Copy link
Member Author

So you are fine with this?

@mario
Copy link
Contributor

mario commented Jun 27, 2017

Well you could run the remove process in a job ...

@tobiasKaminsky
Copy link
Member Author

Sure, but I wanted to have this done on the moment the user clicks on it and not scheduled for sometimes later.

@mario
Copy link
Contributor

mario commented Jun 27, 2017

Solution:

  • strike out the account name (aka, you can't click it)
  • switch to other acc if it exists, if not show login screen
  • run a job (you can schedule it to run after 3 seconds, and in the future you'll be able to schedule it right away :P) with all the delete magic
  • prevent adding the same account while there is pending delete for that account
  • done :D

@AndyScherzinger
Copy link
Member

@tobiasKaminsky yes, that means I am fine with deleting all local files on account removal 👍

@mario
Copy link
Contributor

mario commented Jun 30, 2017

@tobiasKaminsky can you please do the things I've written here so we can merge this?

@tobiasKaminsky
Copy link
Member Author

tobiasKaminsky commented Jul 5, 2017

Done 🎉

Tested with

  • initially 2 accounts, removing one -> manage account activity with striked through account, drawer only shows persisting account
  • initially 1 account, removing one -> login screen

@tobiasKaminsky tobiasKaminsky added this to the Nextcloud App 1.5.0 milestone Jul 12, 2017
@mario
Copy link
Contributor

mario commented Jul 12, 2017

@AndyScherzinger if you feel like this is ok, feel free to merge - I will not be able to review it in a while. Thanks.

- switch to other acc if it exists, if not show login screen
- run a job with all the delete magic
- prevent adding the same account while there is pending delete for that account
@AndyScherzinger AndyScherzinger force-pushed the deleteFilesOnAccountRemoval branch from 5e4f458 to 87ae252 Compare July 16, 2017 16:09
@AndyScherzinger
Copy link
Member

AndyScherzinger commented Jul 16, 2017

👍 tested successfully after latest rebase

Approved with PullApprove

@AndyScherzinger AndyScherzinger merged commit 72243d3 into master Jul 16, 2017
@AndyScherzinger AndyScherzinger deleted the deleteFilesOnAccountRemoval branch July 16, 2017 20:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants