fixed error, all tests pass