Prem Thakur
12/20/2024, 7:35 AMUnable to instantiate receiver com.example.MyBroadCastReceiver: java.lang.ClassCastException: com.example.context.MyContextWrapper cannot be cast to android.app.ContextImpl.
In My Application:
override fun attachBaseContext(base: Context) {
val wrappedContext = MyContextWrapper.wrap(base)
super.attachBaseContext(wrappedContext)
}
Where MyContextWrapper is just a Context Wrapper
TIAChrimaeon
12/20/2024, 9:07 AM