Skip to content

Commit

Permalink
fix: Update build patch for react-native-background-upload
Browse files Browse the repository at this point in the history
react-native-background-upload is not maintained. We already had a
patch for react-native 0.72, but we are getting an error when
uploading a file when targeting Android 34 : "One of
RECEIVER_EXPORTED or RECEIVER_NOT_EXPORTED should be specified when a
receiver isn't being registered exclusively for system broadcasts".

Fix is done in android-upload-service
gotev/android-upload-service#642

New patch is taken from
Vydia/react-native-background-upload#347
  • Loading branch information
zatteo committed Jul 18, 2024
1 parent cb2a08b commit e097ed5
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 44 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
diff --git a/node_modules/react-native-background-upload/android/build.gradle b/node_modules/react-native-background-upload/android/build.gradle
index fa6963f..7a3c908 100755
--- a/node_modules/react-native-background-upload/android/build.gradle
+++ b/node_modules/react-native-background-upload/android/build.gradle
@@ -1,9 +1,9 @@
buildscript {
ext {
- kotlinVersion = '1.6.0'
- buildToolsVersion = '29.0.2'
- compileSdkVersion = 29
- targetSdkVersion = 29
+ kotlinVersion = '1.8.21'
+ buildToolsVersion = '34.0.8'
+ compileSdkVersion = 34
+ targetSdkVersion = 34
minSdkVersion = 18
}
ext.detoxKotlinVersion = ext.kotlinVersion
@@ -20,7 +20,7 @@ buildscript {

apply plugin: 'com.android.library'
apply plugin: 'kotlin-android'
-apply plugin: 'kotlin-android-extensions'
+apply plugin: 'kotlin-parcelize'

def DEFAULT_COMPILE_SDK_VERSION = 28
def DEFAULT_BUILD_TOOLS_VERSION = "28.0.3"
@@ -64,7 +64,7 @@ dependencies {

implementation "org.jetbrains.kotlin:$_kotlinStdlib:$_kotlinVersion"

- implementation 'net.gotev:uploadservice-okhttp:4.7.0'
+ implementation 'net.gotev:uploadservice-okhttp:4.9.2'

implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.0.0'
}
44 changes: 0 additions & 44 deletions patches/react-native-background-upload+6.6.0+002+build-rn-72.patch

This file was deleted.

0 comments on commit e097ed5

Please sign in to comment.