original_string: protected function deleteCollectionItem()
      {
          $this->controlAccess('collection_item_delete');
  
          if ($this->collection_item->delete($this->data_collection_item['collection_item_id'])) {
              $url = "admin/content/collection-item/{$this->data_collection['collection_id']}";
              $this->redirect($url, $this->text('Collection item has been deleted'), 'success');
          }
  
          $this->redirect('', $this->text('Collection item has not been deleted'), 'warning');
      }
code: protected function deleteCollectionItem()
      {
          $this->controlAccess('collection_item_delete');
  
          if ($this->collection_item->delete($this->data_collection_item['collection_item_id'])) {
              $url = "admin/content/collection-item/{$this->data_collection['collection_id']}";
              $this->redirect($url, $this->text('Collection item has been deleted'), 'success');
          }
  
          $this->redirect('', $this->text('Collection item has not been deleted'), 'warning');
      }
code_tokens: protected function deleteCollectionItem ( ) { $ this -> controlAccess ( 'collection_item_delete' ) ; if ( $ this -> collection_item -> delete ( $ this -> data_collection_item [ 'collection_item_id' ] ) ) { $ url = "admin/content/collection-item/{$this->data_collection['collection_id']}" ; $ this -> redirect ( $ url , $ this -> text ( 'Collection item has been deleted' ) , 'success' ) ; } $ this -> redirect ( '' , $ this -> text ( 'Collection item has not been deleted' ) , 'warning' ) ; }
docstring: Delete a collection item
docstring_tokens: Delete a collection item