Improving some variable handling, fix issue with new config validation