Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,15 @@ public void onReceive(Context context, Intent intent) {
* An {@code Intent} containing the channel and data of the current push notification.
*/
protected void onPushReceive(Context context, Intent intent) {
String pushDataStr = intent.getStringExtra(KEY_PUSH_DATA);
if (pushDataStr == null) {
PLog.e(TAG, "Can not get push data from intent.");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

s/Can not get/Unable to read/g

return;
}

JSONObject pushData = null;
try {
pushData = new JSONObject(intent.getStringExtra(KEY_PUSH_DATA));
pushData = new JSONObject(pushDataStr);
} catch (JSONException e) {
PLog.e(TAG, "Unexpected JSONException when receiving push data: ", e);
}
Expand Down