Merge pull request #1113 from judemanutd/patch-2
Resolve display notification promise
This commit is contained in:
commit
bc0326b3bf
|
@ -283,6 +283,11 @@ public class DisplayNotificationTask extends AsyncTask<Void, Void, Void> {
|
||||||
if (reactContext != null) {
|
if (reactContext != null) {
|
||||||
Utils.sendEvent(reactContext, "notifications_notification_displayed", Arguments.fromBundle(notification));
|
Utils.sendEvent(reactContext, "notifications_notification_displayed", Arguments.fromBundle(notification));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (promise != null) {
|
||||||
|
promise.resolve(null);
|
||||||
|
}
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Log.e(TAG, "Failed to send notification", e);
|
Log.e(TAG, "Failed to send notification", e);
|
||||||
if (promise != null) {
|
if (promise != null) {
|
||||||
|
|
Loading…
Reference in New Issue