Hello,

I am using the Cordova SDK on Android. When the app is in the foreground push notifications work as expected. However, when the app is not in the foreground, when tapping on the notification from the notification center the app becomes active again but the push-notification event is not fired in Javascript.

After some investigation I found out that in PushNotifications.java the method getPushFromIntent returns null because intent.hasExtra(PushManager.PUSH_RECEIVE_EVENT) returns false. Could this be the cause of my problem? If so, is this a bug or how can I fix this?

Running on Cordova 5.0.0 and Android 4.4.2

Thanks, Maarten

asked 29 May '15, 08:49
mvandillen's gravatar image

mvandillen
112

Hello Maarten,

Could you please try our Cordova Android Sample and check whether this issue persists?

permanent link
answered 02 Jun '15, 10:33
Max%20Kuzakov's gravatar image

Max Kuzakov
4165

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×446
×444
×190

question asked: 29 May '15, 08:49

question was seen: 1,306 times

last updated: 02 Jun '15, 10:33