Skip to content

Commit bce0f2f

Browse files
committed
protecting all classmembers via consumer-rules.pro
This is a shorterm fix that should be a catch all solution but will increase the size of the SDK. Long term we should change how we are implementing dependency injection so that pro guard can better detect what can be removed. Keep all classes that implement IModule since they use reflection
1 parent c97fdb3 commit bce0f2f

File tree

4 files changed

+24
-4
lines changed

4 files changed

+24
-4
lines changed
Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
11
-dontwarn com.onesignal.**
22

3-
-dontwarn com.amazon.**
3+
-dontwarn com.amazon.**
4+
5+
-keepclassmembers class com.onesignal.core.** { *; }
6+
7+
-keepclassmembers class com.onesignal.session.** { *; }
8+
9+
-keepclassmembers class com.onesignal.user.** { *; }
10+
11+
-keepclassmembers class com.onesignal.internal.** { *; }
12+
13+
-keepclassmembers class com.onesignal.debug.** { *; }
14+
15+
-keepclassmembers class com.onesignal.common.** { *; }
16+
17+
-keep class ** implements com.onesignal.common.modules.IModule { *; }
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
-dontwarn com.onesignal.iam.**
1+
-dontwarn com.onesignal.iam.**
2+
3+
-keepclassmembers class com.onesignal.inAppMessages.** { *; }
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
-dontwarn com.onesignal.location.**
1+
-dontwarn com.onesignal.location.**
2+
3+
-keepclassmembers class com.onesignal.location.** { *; }

OneSignalSDK/onesignal/notifications/consumer-rules.pro

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,4 +48,6 @@
4848

4949
-keep public class com.onesignal.notifications.services.ADMMessageHandlerJob {*;}
5050

51-
-keep class com.onesignal.JobIntentService$* {*;}
51+
-keep class com.onesignal.JobIntentService$* {*;}
52+
53+
-keepclassmembers class com.onesignal.notifications.** { *; }

0 commit comments

Comments
 (0)