original_string: public function write_setting($data) {
          if (!is_array($data)) {
              return '';
          }
          unset($data['xxxxx']);
          $result = 0;
          foreach($data as $index) {
              $result |= 1 << $index;
          }
          return ($this->config_write($this->name, $result) ? '' : get_string('errorsetting', 'admin'));
      }
code: public function write_setting($data) {
          if (!is_array($data)) {
              return '';
          }
          unset($data['xxxxx']);
          $result = 0;
          foreach($data as $index) {
              $result |= 1 << $index;
          }
          return ($this->config_write($this->name, $result) ? '' : get_string('errorsetting', 'admin'));
      }
code_tokens: public function write_setting ( $ data ) { if ( ! is_array ( $ data ) ) { return '' ; } unset ( $ data [ 'xxxxx' ] ) ; $ result = 0 ; foreach ( $ data as $ index ) { $ result |= 1 << $ index ; } return ( $ this -> config_write ( $ this -> name , $ result ) ? '' : get_string ( 'errorsetting' , 'admin' ) ) ; }
docstring: Save the new settings
  
  @param array $data Array of new settings
  @return bool
docstring_tokens: Save the new settings