Project Information
Repository:
https://github.com/AugustToko/ACG-PlayerProject Name: ACG-Player
The issue submitted on GitHub: https://github.com/AugustToko/ACG-Player/issues/40
My github link: https://github.com/darewealth
Describe the bug
When I play music on the app and I minimize and reopen, the app crashed.
To Reproduce
Launch the app
Play any music and minimize the app
Launch again
See error
Expected behavior
I expect to see the app working normally after relaunch.
Screenshots
Smartphone
Device: [Gionee X1]
OS: [7.0]
Version [2.6.5.3.20190530]
Log
05-30 14:49:07.770 24583 24583 E AndroidRuntime: Process: top.geek_studio.chenlongcould.musicplayer.Common, PID: 24583
05-30 14:49:07.770 24583 24583 E AndroidRuntime: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String android.net.Uri.getScheme()' on a null object reference
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at top.geek_studio.chenlongcould.musicplayer.broadcast.ReceiverOnMusicPlay.playFromUri(SourceFile:2)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at top.geek_studio.chenlongcould.musicplayer.activity.MainActivity.receivedIntentCheck(SourceFile:6)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at top.geek_studio.chenlongcould.musicplayer.activity.MainActivity.onNewIntent(SourceFile:2)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.Instrumentation.callActivityOnNewIntent(Instrumentation.java:1215)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.Instrumentation.callActivityOnNewIntent(Instrumentation.java:1227)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.ActivityThread.deliverNewIntents(ActivityThread.java:2546)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.ActivityThread.performNewIntents(ActivityThread.java:2558)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.ActivityThread.handleNewIntent(ActivityThread.java:2567)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.ActivityThread.-wrap12(ActivityThread.java)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1417)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5452)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:781)
05-30 14:49:07.770 24583 24583 E AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:671)```