original_string: public function delete_capabilities() {
          global $DB;
  
          $ids = $DB->get_fieldset_select('role_capabilities', 'DISTINCT roleid', 'contextid = ?', array($this->_id));
          if ($ids) {
              $DB->delete_records('role_capabilities', array('contextid' => $this->_id));
  
              // Reset any cache of these roles, including MUC.
              accesslib_clear_role_cache($ids);
          }
      }
code: public function delete_capabilities() {
          global $DB;
  
          $ids = $DB->get_fieldset_select('role_capabilities', 'DISTINCT roleid', 'contextid = ?', array($this->_id));
          if ($ids) {
              $DB->delete_records('role_capabilities', array('contextid' => $this->_id));
  
              // Reset any cache of these roles, including MUC.
              accesslib_clear_role_cache($ids);
          }
      }
code_tokens: public function delete_capabilities ( ) { global $ DB ; $ ids = $ DB -> get_fieldset_select ( 'role_capabilities' , 'DISTINCT roleid' , 'contextid = ?' , array ( $ this -> _id ) ) ; if ( $ ids ) { $ DB -> delete_records ( 'role_capabilities' , array ( 'contextid' => $ this -> _id ) ) ; // Reset any cache of these roles, including MUC. accesslib_clear_role_cache ( $ ids ) ; } }
docstring: Unassign all capabilities from a context.
docstring_tokens: Unassign all capabilities from a context .