diff --git a/android/build.gradle b/android/build.gradle index 95dbd54..ade2dc9 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -27,7 +27,10 @@ def getExtOrIntegerDefault(name) { } android { - // namespace 'com.rivereactnative' + // Conditional for compatibility with AGP <4.2. + if (project.android.hasProperty("namespace")) { + namespace = "com.rivereactnative" + } compileSdkVersion getExtOrIntegerDefault('compileSdkVersion') buildToolsVersion getExtOrDefault('buildToolsVersion') defaultConfig {