0

作为 Google Play Servies 8.3.0 的一部分,我从 Google+ 登录切换到新的Google 登录,并得到了:

BadParcelableException: Parcelable protocol requires a Parcelable.Creator object called CREATOR on class com.google.android.gms.auth.TokenDat

在:

GoogleAuthUtil.getToken(getApplicationContext(), email, scopes);

如何防止 BadParcelableException?

4

1 回答 1

0

您必须通过添加以下内容来防止 ProGuard/DexGuard 在新com.google.android.gms.auth包中剥离所需的类:

-keep public class com.google.android.gms.auth.** { public *; }

到您的proguard-project.txtdexguard-project.txt文件。

于 2015-11-14T15:05:07.197 回答