fixed error for post model