Skip to content

Commit

Permalink
code optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
samwelnyandoro committed Jul 4, 2024
1 parent 2f144bb commit e76ed9b
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@

public class MPESAMessagingService extends FirebaseMessagingService {
private static final String TAG = "MPESAMessagingService";

/**
* Called when message is received.
*
Expand All @@ -39,7 +38,7 @@ public void onMessageReceived(RemoteMessage remoteMessage) {
//Log.d(TAG, "From: " + remoteMessage.getFrom());

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

handleNow(remoteMessage.getData().toString());
Expand Down

0 comments on commit e76ed9b

Please sign in to comment.