fixing null config copy test failures and minor bugs

 (thanks @andyli)