mirror of
https://github.com/M66B/FairEmail.git
synced 2024-12-26 09:47:13 +00:00
Prevent crash
This commit is contained in:
parent
297cf9ca82
commit
595fa5ad23
1 changed files with 4 additions and 1 deletions
|
@ -153,7 +153,7 @@ public class FragmentOperations extends FragmentBase {
|
||||||
new SimpleTask<Integer>() {
|
new SimpleTask<Integer>() {
|
||||||
@Override
|
@Override
|
||||||
protected void onPostExecute(Bundle args) {
|
protected void onPostExecute(Bundle args) {
|
||||||
ToastEx.makeText(context, R.string.title_executing, Toast.LENGTH_LONG).show();
|
ToastEx.makeText(getContext(), R.string.title_executing, Toast.LENGTH_LONG).show();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -221,6 +221,9 @@ public class FragmentOperations extends FragmentBase {
|
||||||
protected void onExecuted(Bundle args, Integer deleted) {
|
protected void onExecuted(Bundle args, Integer deleted) {
|
||||||
if (deleted == null)
|
if (deleted == null)
|
||||||
deleted = -1;
|
deleted = -1;
|
||||||
|
Context context = getContext();
|
||||||
|
if (context == null)
|
||||||
|
return;
|
||||||
ToastEx.makeText(
|
ToastEx.makeText(
|
||||||
context,
|
context,
|
||||||
getString(R.string.title_delete_operation_deleted, deleted),
|
getString(R.string.title_delete_operation_deleted, deleted),
|
||||||
|
|
Loading…
Reference in a new issue