Skip to content

Commit 4946614

Browse files
author
Krzysztof Borowy
committed
change flag name
1 parent a545d0a commit 4946614

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

android/build.gradle

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,10 @@ if( newDbSize != null && newDbSize.isLong()) {
6161

6262
// Instead of reusing AsyncTask thread pool, AsyncStorage can use its own executor
6363
def useDedicatedExecutor = getFlagOrDefault('AsyncStorage_dedicatedExecutor', false)
64-
def useRoomImplementation = getFlagOrDefault("AsyncStorage_useRoomLibrary", false)
64+
def useNext = getFlagOrDefault("AsyncStorage_useNext", false)
6565

6666
apply plugin: 'com.android.library'
67-
if(useRoomImplementation) {
67+
if(useNext) {
6868
apply plugin: 'kotlin-android'
6969
apply plugin: 'kotlin-kapt'
7070
}
@@ -77,7 +77,7 @@ android {
7777
targetSdkVersion safeExtGet('targetSdkVersion', 28)
7878
buildConfigField "Long", "AsyncStorage_db_size", "${dbSizeInMB}L"
7979
buildConfigField "boolean", "AsyncStorage_useDedicatedExecutor", "${useDedicatedExecutor}"
80-
buildConfigField "boolean", "AsyncStorage_useRoomLibrary", "${useRoomImplementation}"
80+
buildConfigField "boolean", "AsyncStorage_useNext", "${useNext}"
8181
}
8282
lintOptions {
8383
abortOnError false
@@ -95,7 +95,7 @@ repositories {
9595

9696
dependencies {
9797

98-
if(useRoomImplementation) {
98+
if(useNext) {
9999
def room_version = "2.2.6"
100100
def coroutines_version = "1.3.9"
101101

android/src/main/java/com/reactnativecommunity/asyncstorage/AsyncStoragePackage.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public List<NativeModule> createNativeModules(ReactApplicationContext reactConte
2424

2525
List<NativeModule> moduleList = new ArrayList<>(1);
2626

27-
if (BuildConfig.AsyncStorage_useRoomLibrary) {
27+
if (BuildConfig.AsyncStorage_useNext) {
2828
try {
2929
Class storageClass = Class.forName("com.reactnativecommunity.asyncstorage.next.StorageModule");
3030
NativeModule inst = (NativeModule) storageClass.getDeclaredConstructor(new Class[]{ReactContext.class}).newInstance(reactContext);

example/android/gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
# Enable dedicated thread pool executor
2424
AsyncStorage_dedicatedExecutor=true
25-
AsyncStorage_useRoomLibrary=true
25+
AsyncStorage_useNext=true
2626

2727
android.useAndroidX=true
2828
android.enableJetifier=true

0 commit comments

Comments
 (0)