Berndhura / LuftKraftSport

1 stars 0 forks source link

push nachrichten wieder gangbar machen #116

Open Berndhura opened 4 years ago

Berndhura commented 4 years ago
Berndhura commented 4 years ago

Log.d(TAG, "From: " + remoteMessage.getFrom());

// Check if message contains a data payload.
if (remoteMessage.getData().size() > 0) {
    Log.d(TAG, "Message data payload: " + remoteMessage.getData());

    if (/* Check if data needs to be processed by long running job */ true) {
        // For long-running tasks (10 seconds or more) use WorkManager.
        scheduleJob();
    } else {
        // Handle message within 10 seconds
        handleNow();
    }

}

// Check if message contains a notification payload.
if (remoteMessage.getNotification() != null) {
    Log.d(TAG, "Message Notification Body: " + remoteMessage.getNotification().getBody());
}