fix: fix crash when onDenied runnable is null on dialogs
This commit is contained in:
@@ -400,7 +400,10 @@ public class UiUtils {
|
|||||||
.setTitle(title)
|
.setTitle(title)
|
||||||
.setMessage(message)
|
.setMessage(message)
|
||||||
.setPositiveButton(confirmButton, (dlg, i)->onConfirmed.run())
|
.setPositiveButton(confirmButton, (dlg, i)->onConfirmed.run())
|
||||||
.setNegativeButton(R.string.cancel, (dialog, which) -> onDenied.run())
|
.setNegativeButton(R.string.cancel, (dialog, which) -> {
|
||||||
|
if (onDenied != null)
|
||||||
|
onDenied.run();
|
||||||
|
})
|
||||||
.setIcon(icon)
|
.setIcon(icon)
|
||||||
.show();
|
.show();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user