/** * Update path field * * @param \Mageplaza\Blog\Model\Category $object * @return $this */ protected function savePath($object) { if ($object->getId()) { $this->getConnection()->update($this->getMainTable(), ['path' => $object->getPath()], ['category_id = ?' => $object->getId()]); $object->unsetData('path_ids'); } return $this; }