original_string: protected function deleteLinked($page_id)
      {
          $this->db->delete('page_translation', array('page_id' => $page_id));
          $this->db->delete('file', array('entity' => 'page', 'entity_id' => $page_id));
          $this->db->delete('alias', array('entity' => 'page', 'entity_id' => $page_id));
  
          $sql = 'DELETE ci
                  FROM collection_item ci
                  INNER JOIN collection c ON(ci.collection_id = c.collection_id)
                  WHERE c.type = ? AND ci.entity_id = ?';
  
          $this->db->run($sql, array('page', $page_id));
      }
code: protected function deleteLinked($page_id)
      {
          $this->db->delete('page_translation', array('page_id' => $page_id));
          $this->db->delete('file', array('entity' => 'page', 'entity_id' => $page_id));
          $this->db->delete('alias', array('entity' => 'page', 'entity_id' => $page_id));
  
          $sql = 'DELETE ci
                  FROM collection_item ci
                  INNER JOIN collection c ON(ci.collection_id = c.collection_id)
                  WHERE c.type = ? AND ci.entity_id = ?';
  
          $this->db->run($sql, array('page', $page_id));
      }
code_tokens: protected function deleteLinked ( $ page_id ) { $ this -> db -> delete ( 'page_translation' , array ( 'page_id' => $ page_id ) ) ; $ this -> db -> delete ( 'file' , array ( 'entity' => 'page' , 'entity_id' => $ page_id ) ) ; $ this -> db -> delete ( 'alias' , array ( 'entity' => 'page' , 'entity_id' => $ page_id ) ) ; $ sql = 'DELETE ci
                  FROM collection_item ci
                  INNER JOIN collection c ON(ci.collection_id = c.collection_id)
                  WHERE c.type = ? AND ci.entity_id = ?' ; $ this -> db -> run ( $ sql , array ( 'page' , $ page_id ) ) ; }
docstring: Deletes all database records related to the page ID
  @param int $page_id
docstring_tokens: Deletes all database records related to the page ID