Move some logic for getting config values to CAutoConfig