Skip to content

Commit

Permalink
[Android]: Check if message is not a registration confirmation
Browse files Browse the repository at this point in the history
  • Loading branch information
danielpassos committed Jun 16, 2015
1 parent b93bad6 commit 077bfdc
Showing 1 changed file with 5 additions and 3 deletions.
Expand Up @@ -46,10 +46,12 @@ public void onMessage(Context context, Bundle bundle) {

String message = bundle.getString(UnifiedPushMessage.ALERT_KEY);

HelloWorldApplication application = (HelloWorldApplication) context.getApplicationContext();
application.addMessage(message);
if(message != null) {
HelloWorldApplication application = (HelloWorldApplication) context.getApplicationContext();
application.addMessage(message);

notify(bundle);
notify(bundle);
}
}

private void notify(Bundle bundle) {
Expand Down

0 comments on commit 077bfdc

Please sign in to comment.