title: Android Notification during app is in background, intent data is empty
body: <p>I'm using this code, when the app is in the foreground it was working perfectly. but the notification coming during app is in background Intent does not have any data.</p>
  
  <pre><code> Intent intent = new Intent(this, SplashActivity.class);
  
      intent.putExtra(Constant.device_id,deviceId);
      intent.putExtra(Constant.isFromPush,true);
      intent.addFlags( Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_NEW_TASK );
      PendingIntent pendingIntent = PendingIntent.getActivity(this, 0 /* Request code */, intent,
              PendingIntent.FLAG_ONE_SHOT);
  
      String channelId = getString(R.string.default_notification_channel_id);
      Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);
      NotificationCompat.Builder notificationBuilder =
              new NotificationCompat.Builder(this, channelId)
                      .setSmallIcon(R.mipmap.ic_launcher)
                      .setContentTitle(title_)
                      .setContentText(message)
                      .setAutoCancel(true)
                      .setSound(defaultSoundUri)
                      .setContentIntent(pendingIntent);
  
      NotificationManager notificationManager =
              (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);
  
      // Since android Oreo notification channel is needed.
      if (Build.VERSION.SDK_INT &gt;= Build.VERSION_CODES.O) {
          NotificationChannel channel = new NotificationChannel(channelId,
                  getString(R.string.app_name),
                  NotificationManager.IMPORTANCE_DEFAULT);
          notificationManager.createNotificationChannel(channel);
      }
  
      notificationManager.notify(new Random().nextInt( 2000 ) /* ID of notification */, notificationBuilder.build());
  </code></pre>