Alpha Release 0.2.1 #119

Merged
niggl merged 34 commits from dev into main 2021-01-21 17:31:51 +00:00
Showing only changes of commit e12aedd1aa - Show all commits

View File

@ -10,7 +10,7 @@ export const config = {
phone_validation_countrycode: getPhoneCodeLocale(),
postalcode_validation_countrycode: getPostalCodeLocale(),
version: process.env.VERSION || require('../package.json').version,
seedTestData: JSON.parse(process.env.SEED_TEST_DATA) || false
seedTestData: getDataSeeding()
}
let errors = 0
if (typeof config.internal_port !== "number") {
@ -31,4 +31,11 @@ function getPostalCodeLocale(): any {
return null;
}
}
function getDataSeeding(): Boolean {
try {
return JSON.parse(process.env.SEED_TEST_DATA);
} catch (error) {
return false;
}
}
export let e = errors