mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-29 09:58:54 +03:00
Use lambdas
Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
parent
0695d9fd73
commit
97423444ce
1 changed files with 2 additions and 12 deletions
|
@ -237,22 +237,12 @@ public class SwitchAccountController extends BaseController {
|
||||||
Log.e(TAG, "Access was denied");
|
Log.e(TAG, "Access was denied");
|
||||||
ErrorMessageHolder.getInstance().setMessageType(
|
ErrorMessageHolder.getInstance().setMessageType(
|
||||||
ErrorMessageHolder.ErrorMessageType.FAILED_TO_IMPORT_ACCOUNT);
|
ErrorMessageHolder.ErrorMessageType.FAILED_TO_IMPORT_ACCOUNT);
|
||||||
new Handler().post(new Runnable() {
|
new Handler().post(() -> getRouter().popToRoot());
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
getRouter().popToRoot();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Log.e(TAG, "Something went wrong while accessing token");
|
Log.e(TAG, "Something went wrong while accessing token");
|
||||||
ErrorMessageHolder.getInstance().setMessageType(
|
ErrorMessageHolder.getInstance().setMessageType(
|
||||||
ErrorMessageHolder.ErrorMessageType.FAILED_TO_IMPORT_ACCOUNT);
|
ErrorMessageHolder.ErrorMessageType.FAILED_TO_IMPORT_ACCOUNT);
|
||||||
new Handler().post(new Runnable() {
|
new Handler().post(() -> getRouter().popToRoot());
|
||||||
@Override
|
|
||||||
public void run() {
|
|
||||||
getRouter().popToRoot();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
}, handler
|
}, handler
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue