diff options
author | Harsh Shandilya <msfjarvis@gmail.com> | 2019-01-03 16:24:45 +0530 |
---|---|---|
committer | حسين <zidhussein@gmail.com> | 2019-01-03 10:54:45 +0000 |
commit | f34ce30cc7acf3e2178a57ba0cbcb7103937c272 (patch) | |
tree | 550952f3fa9fee88e1ada53ceaa7ec7c543bb6a5 | |
parent | 249248e168a152e7502ba331bf86ab88c7815110 (diff) |
GitOperation: Dismiss activity on cancel (#468)
Fixes the issue where starting a repository sync and then
hitting cancel in the password dialog leaves you with an empty activity
which needs to be dismissed to get back to where you were.
Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com>
-rw-r--r-- | app/src/main/java/com/zeapo/pwdstore/git/GitOperation.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/app/src/main/java/com/zeapo/pwdstore/git/GitOperation.java b/app/src/main/java/com/zeapo/pwdstore/git/GitOperation.java index 7f6ecd81..51ea92d3 100644 --- a/app/src/main/java/com/zeapo/pwdstore/git/GitOperation.java +++ b/app/src/main/java/com/zeapo/pwdstore/git/GitOperation.java @@ -203,9 +203,8 @@ public abstract class GitOperation { // authenticate using the user/pwd and then execute the command setAuthentication(username, password.getText().toString()).execute(); - }).setNegativeButton(callingActivity.getResources().getString(R.string.dialog_cancel), (dialog, whichButton) -> { - // Do nothing. - }).show(); + }) + .setNegativeButton(callingActivity.getResources().getString(R.string.dialog_cancel), (dialog, whichButton) -> callingActivity.finish()).show(); } } |