diff --git a/README.md b/README.md index 14f4fb6..9eaf6bc 100644 --- a/README.md +++ b/README.md @@ -97,11 +97,11 @@ dependencies { ```text # 必须要加上此规则,否则会导致泛型解析失败 --keep public class * implements com.hjq.http.listener.OnHttpListener { +-keep class * implements com.hjq.http.listener.OnHttpListener { *; } --keep public class * extends com.hjq.http.model.ResponseClass { +-keep class * extends com.hjq.http.model.ResponseClass { *; } ``` diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index a3c22dd..fcfe257 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -35,7 +35,11 @@ # EasyHttp -keep class com.hjq.http.** {*;} # 必须要加上此规则,否则会导致泛型解析失败 --keep public class * implements com.hjq.http.listener.OnHttpListener { +-keep class * implements com.hjq.http.listener.OnHttpListener { + *; +} + +-keep class * extends com.hjq.http.model.ResponseClass { *; }