1
builder = new NotificationCompat.Builder(Objects.requireNonNull(getContext()),"M_CH_ID");
builder.setSmallIcon(R.drawable.icon_notificacao)
.setContentTitle("RPfm 105.3")
.setContentText("Ao Vivo")
.setAutoCancel(true);
NotificationManager notifyManager = (NotificationManager) Objects.<FragmentActivity>requireNonNull(getActivity()).getSystemService(Context.NOTIFICATION_SERVICE);
if(notifyManager != null) {
notifyManager.notify(1, builder.build());
}
This code was working before updating the android studio. Someone Sab oq might be. In the Log no nda error, and already debugged, it calls the method, no longer displays the notification.
Which API is using ?
– NoobSaibot
I’m using version 27
– Robson Cabral