fix more problems caused by cut-n-paste