I am writing an application on Cordova. I need it to work in the background. Put the plugin - link

Everything works, but not on version 8.1.0. On this version, the application "falls", that is, knocks out a message that the application is stopped.

What could be the problem?

PS error code

android.app.RemoteServiceException: Bad notification for startForeground: java.Iang.RuntimeException: invalid channel for service notification: Notification(channel=null pri=-2 contentView=null vibrate=null sound=null defaults=OxO flags=0x42 color=0x00000000 vis=PRIVATE) at android.app.ActivityThread$H.handleMessage(ActivityThread. java:1794) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:176) at android.app.ActivityThread.main(ActivityThread.java: 6635) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.Runtimelnit$MethodAndArgsCaller.ru n(Runtimelnit.java:547) at com.android.internal.os.Zygotelnit.main(Zygotelnit.java: 823) 
  • The reason is written in the logs, read - andreymal
  • the problem is that I do not understand what the error is - joxi.ru/Vm6oew0F47PZX2 - Diefair
  • Put the text of the error in the question itself (the text, not the picture) - andreymal
  • one
    Why cordova? Although your choice, port yourself: stackoverflow.com/questions/47531742/… . The problem is that there are no notification channels. For the old version of the rules, it worked like this: val notificationBuilder = NotificationCompat.Builder (this). Now you need this: val notificationBuilder = NotificationCompat.Builder (this, channelId). And plus implementation. The implementation is not necessary - just checked. The main thing is to enter channelId, for example: "myChannel" - Valeriy

0