Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ClassCastException when getBoolean #230

Closed
longlinht opened this issue May 10, 2021 · 1 comment
Closed

ClassCastException when getBoolean #230

longlinht opened this issue May 10, 2021 · 1 comment
Assignees

Comments

@longlinht
Copy link

Basic environment info:

System version 4.2.2

Java version 8

Gradle version 6.6.1

Android Gradle plugin version 4.0.0

Booster version 3.1.0

Stack traces

Caused by java.lang.ClassCastException
java.lang.Integer cannot be cast to java.lang.Boolean

com.didiglobal.booster.instrument.sharedpreferences.BoosterSharedPreferences.getBoolean (BoosterSharedPreferences.java:120)
cn.xiaochuankeji.zuiyouLite.common.instance.SelectGenderDlgManager.<init> (SelectGenderDlgManager.java:95)
cn.xiaochuankeji.zuiyouLite.common.instance.SelectGenderDlgManager.getInstance (SelectGenderDlgManager.java:71)
cn.xiaochuankeji.zuiyouLite.ui.main.MainActivity.onCreate (MainActivity.java:236)
android.app.Activity.performCreate (Activity.java:5112)
android.app.Instrumentation.callActivityOnCreate (Instrumentation.java:1080)
android.app.ActivityThread.performLaunchActivity (ActivityThread.java:2214)
android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2300)
android.app.ActivityThread.access$700 (ActivityThread.java:156)
android.app.ActivityThread$H.handleMessage (ActivityThread.java:1298)
android.os.Handler.dispatchMessage (Handler.java:99)
android.os.Looper.loop (Looper.java:137)
android.app.ActivityThread.main (ActivityThread.java:5211)
java.lang.reflect.Method.invokeNative (Method.java)
java.lang.reflect.Method.invoke (Method.java:511)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:815)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:582)
dalvik.system.NativeStart.main (NativeStart.java)

After using booster, received many this type of crash in firebase console. Most occurred in Samsung Android 4, 4.2.2 is most, I' m sure that I save boolean value properly, so please let me know whether I use booster improperly or this is bug.

@johnsonlee
Copy link
Collaborator

BoosterSharedPreferences has been deprecated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants