diff --git a/app/build.gradle b/app/build.gradle index 7633c13..643628d 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -30,6 +30,8 @@ android { } dependencies { + //butter knife + implementation libs.firebase.messaging implementation libs.core //The mpesa Library implementation project(':mpesa') diff --git a/app/src/main/java/com/mpesaandroidintegration/mpesaintegrationandroid/MPESAInstanceIDService.java b/app/src/main/java/com/mpesaandroidintegration/mpesaintegrationandroid/MPESAInstanceIDService.java index 26e8f2c..c437634 100644 --- a/app/src/main/java/com/mpesaandroidintegration/mpesaintegrationandroid/MPESAInstanceIDService.java +++ b/app/src/main/java/com/mpesaandroidintegration/mpesaintegrationandroid/MPESAInstanceIDService.java @@ -2,12 +2,15 @@ import android.content.SharedPreferences; import android.util.Log; + +import androidx.annotation.NonNull; + import com.google.firebase.messaging.FirebaseMessagingService; public class MPESAInstanceIDService extends FirebaseMessagingService { private static final String TAG = "MPESAInstanceIDService"; @Override - public void onNewToken(String token) { + public void onNewToken(@NonNull String token) { Log.d(TAG, "Refreshed token: " + token); // Save token to shared preferences