/** * sets $this->category with a category object where the id is $id * * @param $id */ public function setCatById($id) { $this->category = Category::constructCatByID($id); }