1
0
mirror of https://github.com/dzeiocom/OpenHealth.git synced 2025-04-23 19:32:11 +00:00

fix: error when keystore is not available

This commit is contained in:
Florian Bouillon 2022-08-22 12:36:15 +02:00
parent 5049c8afa4
commit 57eef94f31

View File

@ -16,16 +16,19 @@ android {
create("release") { create("release") {
val keystoreProperties = Properties().apply { try {
load(rootProject.file("./keystore.properties").reader()) val keystoreProperties = Properties().apply {
} load(rootProject.file("./keystore.properties").reader())
}
if (keystoreProperties.isNotEmpty()) {
storePassword = keystoreProperties["storePassword"] as String
keyPassword = keystoreProperties["keyPassword"] as String
keyAlias = keystoreProperties["keyAlias"] as String
storeFile = file(keystoreProperties["storeFile"] as String)
}
} catch (e: Exception) {}
if (keystoreProperties.isNotEmpty()) {
storePassword = keystoreProperties["storePassword"] as String
keyPassword = keystoreProperties["keyPassword"] as String
keyAlias = keystoreProperties["keyAlias"] as String
storeFile = file(keystoreProperties["storeFile"] as String)
}
} }
} }