2
0
mirror of https://github.com/KDE/kdeconnect-android synced 2025-08-30 13:47:41 +00:00

Fix NPE crash

This commit is contained in:
Albert Vaca Cintora 2025-01-23 11:58:08 +01:00
parent 49d36d57a6
commit 3e2c077674
No known key found for this signature in database

View File

@ -70,7 +70,11 @@ class PresenterActivity : AppCompatActivity(), SensorEventListener {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
plugin = KdeConnect.getInstance().getDevicePlugin(intent.getStringExtra("deviceId"), PresenterPlugin::class.java)!!
plugin = KdeConnect.getInstance().getDevicePlugin(intent.getStringExtra("deviceId"), PresenterPlugin::class.java)
?: run {
finish()
return
}
setContent { PresenterScreen() }
createMediaSession()
}