fixing model error