fix testnet (#227)

* fix testnet

* -move buildConfigFiled inside flavour
-rename SERVER_URL to DEFAULT_SERVER_URL
This commit is contained in:
Eljo Prifti 2021-02-01 00:26:58 +01:00 committed by GitHub
parent c841423b82
commit 93ed588073
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -38,11 +38,13 @@ android {
zcashtestnet {
dimension 'network'
applicationId 'cash.z.ecc.android.testnet'
buildConfigField "String", "DEFAULT_SERVER_URL", '"lightwalletd.testnet.electriccoin.co"'
matchingFallbacks = ['zcashtestnet', 'debug']
}
zcashmainnet {
dimension 'network'
buildConfigField "String", "DEFAULT_SERVER_URL", '"lightwalletd.electriccoin.co"'
matchingFallbacks = ['zcashmainnet', 'release']
}
}

View File

@ -1,5 +1,7 @@
package cash.z.ecc.android.ext
import cash.z.ecc.android.BuildConfig
object Const {
/**
* Named objects for Dependency Injection.
@ -42,7 +44,7 @@ object Const {
object Default {
object Server {
// If you've forked the ECC repo, change this to your hosted lightwalletd instance
const val HOST = "lightwalletd.electriccoin.co"//"your.hosted.lightwalletd.org"
const val HOST = BuildConfig.DEFAULT_SERVER_URL
const val PORT = 9067
}
}