/** * Execute a delete on the associated index and type * * @param BaseElasticsearchEntity $entity * @param bool $refresh */ public function delete($entity, $refresh = false) { $this->_sm->remove($entity); $this->_sm->flush($entity, $refresh); }