Fix a bug such that different .env can be read according to android flavour (#195)

This commit is contained in:
Anson Yao 2017-12-08 17:34:35 -08:00 committed by Pedro Belo
parent 74a6c8df09
commit 7f59748c0b
1 changed files with 1 additions and 1 deletions

View File

@ -33,7 +33,7 @@ def loadDotEnv(flavor = getCurrentFlavor()) {
} else if (project.hasProperty("envConfigFiles")) {
// use startsWith because sometimes the task is "generateDebugSources", so we want to match "debug"
project.ext.envConfigFiles.any { pair ->
if (currentFlavor.startsWith(pair.key)) {
if (flavor.startsWith(pair.key)) {
envFile = pair.value
return true
}