fixed error in case