add some safety checks for where config values are used