fix more of the bug