Skip to content

Commit be18ed5

Browse files
authored
fix(core): prevent Proguard from optimizing away custom ser/de classes (#10982)
1 parent c901d9f commit be18ed5

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

.changes/fix-android-proguard.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri": patch:bug
3+
---
4+
5+
Add a Proguard rule to prevent custom JSON deserializer and serializer classes from being optimized away.

crates/tauri/mobile/android/proguard-rules.pro

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,14 @@
2828
*;
2929
}
3030

31+
-keep @com.fasterxml.jackson.databind.annotation.JsonDeserialize public class * {
32+
*;
33+
}
34+
35+
-keep @com.fasterxml.jackson.databind.annotation.JsonSerialize public class * {
36+
*;
37+
}
38+
3139
-keep class * extends com.fasterxml.jackson.databind.JsonDeserializer { *; }
40+
41+
-keep class * extends com.fasterxml.jackson.databind.JsonSerializer { *; }

0 commit comments

Comments
 (0)