Set env after reading from environment file

master
Mark Moffat 2019-12-18 19:32:15 +10:30
parent 2dabd7a32e
commit cbfb5fa84e
1 changed files with 6 additions and 6 deletions

View File

@ -213,12 +213,6 @@ const getConfig = () => {
config.footerHtml = typeof config.footerHtml !== 'undefined' ? escape.decode(config.footerHtml) : null;
config.googleAnalytics = typeof config.googleAnalytics !== 'undefined' ? escape.decode(config.googleAnalytics) : null;
// set the environment for files
config.env = '.min';
if(process.env.NODE_ENV === 'development' || process.env.NODE_ENV === undefined){
config.env = '';
}
// setup theme
config.themeViews = '';
if(typeof config.theme === 'undefined' || config.theme === ''){
@ -234,6 +228,12 @@ const getConfig = () => {
}
});
// set the environment for files
config.env = '.min';
if(process.env.NODE_ENV === 'development' || process.env.NODE_ENV === undefined){
config.env = '';
}
return config;
};