Merge branch 'main' into develop
This commit is contained in:
commit
d5486463a8
@ -39,7 +39,7 @@ allprojects {
|
||||
ext {
|
||||
androidApplicationId = 'org.cryptomator'
|
||||
androidVersionCode = getVersionCode()
|
||||
androidVersionName = '1.6.4'
|
||||
androidVersionName = '1.7.0-SNAPSHOT'
|
||||
}
|
||||
repositories {
|
||||
mavenCentral()
|
||||
|
@ -12,7 +12,6 @@ import androidx.multidex.MultiDexApplication
|
||||
import org.cryptomator.data.cloud.crypto.Cryptors
|
||||
import org.cryptomator.data.cloud.crypto.CryptorsModule
|
||||
import org.cryptomator.data.repository.RepositoryModule
|
||||
import org.cryptomator.domain.Vault
|
||||
import org.cryptomator.presentation.di.HasComponent
|
||||
import org.cryptomator.presentation.di.component.ApplicationComponent
|
||||
import org.cryptomator.presentation.di.component.DaggerApplicationComponent
|
||||
@ -124,7 +123,11 @@ class CryptomatorApp : MultiDexApplication(), HasComponent<ApplicationComponent>
|
||||
fun startAutoUpload() {
|
||||
val sharedPreferencesHandler = SharedPreferencesHandler(applicationContext())
|
||||
if (checkToStartAutoImageUpload(sharedPreferencesHandler)) {
|
||||
val vault: Vault? = applicationComponent.vaultRepository().load(sharedPreferencesHandler.photoUploadVault())
|
||||
val vault = try {
|
||||
applicationComponent.vaultRepository().load(sharedPreferencesHandler.photoUploadVault())
|
||||
} catch (e: NullPointerException) {
|
||||
null
|
||||
}
|
||||
if (vault?.isUnlocked == true) {
|
||||
val cloud = applicationComponent.cloudRepository().decryptedViewOf(vault)
|
||||
applicationContext().startService(AutoUploadService.startAutoUploadIntent(applicationContext(), cloud))
|
||||
|
Loading…
x
Reference in New Issue
Block a user