Fixing bugs after test.