bug fixes, model.equals