From ceb2e8ba727e3ecc150f01b412142d28b521be6a Mon Sep 17 00:00:00 2001 From: Jhen Date: Thu, 7 Dec 2023 13:54:42 +0800 Subject: [PATCH] fix(android): add namespace if gradle version >= 7 --- android/build.gradle | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/android/build.gradle b/android/build.gradle index 3693a55..bd10eb2 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -36,6 +36,10 @@ def reactNativeArchitectures() { } android { + def agpVersion = com.android.Version.ANDROID_GRADLE_PLUGIN_VERSION + if (agpVersion.tokenize('.')[0].toInteger() >= 7) { + namespace "com.rnwhisper" + } ndkVersion getExtOrDefault("ndkVersion") compileSdkVersion getExtOrIntegerDefault("compileSdkVersion")