fix(app): release builds keep JNI-called plugin code, so settings, sign-in and drafts are saved on the phone

This commit is contained in:
2026-10-24 00:16:21 +01:00
parent 7ec5b52793
commit f28418cc62
3 changed files with 33 additions and 0 deletions
+8
View File
@@ -0,0 +1,8 @@
# Flutter plugins whose Dart side calls Java/Kotlin through JNI (jni/jnigen,
# e.g. shared_preferences_android, path_provider_android). R8 cannot see those
# calls, so it would strip or rename the methods and every call fails at run
# time with NoSuchMethodError (saved settings, sign-in and drafts were lost).
-keep class io.flutter.plugins.** { *; }
-keep class com.github.dart_lang.jni.** { *; }
-keep class kotlin.** { *; }
-keep class kotlinx.coroutines.** { *; }