added config evironment check