original_string: public static function remove($groupname)
      {
          $grav = Grav::instance();
  
          /** @var Config $config */
          $config = $grav['config'];
  
          $blueprints = new Blueprints();
          $blueprint = $blueprints->get('user/group');
  
          $type = 'groups';
  
          $groups = $config->get($type);
          unset($groups[$groupname]);
          $config->set($type, $groups);
  
          $filename = CompiledYamlFile::instance($grav['locator']->findResource("config://{$type}.yaml"));
  
          $obj = new Data($groups, $blueprint);
          $obj->file($filename);
          $obj->save();
  
          return true;
      }
code: public static function remove($groupname)
      {
          $grav = Grav::instance();
  
          /** @var Config $config */
          $config = $grav['config'];
  
          $blueprints = new Blueprints();
          $blueprint = $blueprints->get('user/group');
  
          $type = 'groups';
  
          $groups = $config->get($type);
          unset($groups[$groupname]);
          $config->set($type, $groups);
  
          $filename = CompiledYamlFile::instance($grav['locator']->findResource("config://{$type}.yaml"));
  
          $obj = new Data($groups, $blueprint);
          $obj->file($filename);
          $obj->save();
  
          return true;
      }
code_tokens: public static function remove ( $ groupname ) { $ grav = Grav :: instance ( ) ; /** @var Config $config */ $ config = $ grav [ 'config' ] ; $ blueprints = new Blueprints ( ) ; $ blueprint = $ blueprints -> get ( 'user/group' ) ; $ type = 'groups' ; $ groups = $ config -> get ( $ type ) ; unset ( $ groups [ $ groupname ] ) ; $ config -> set ( $ type , $ groups ) ; $ filename = CompiledYamlFile :: instance ( $ grav [ 'locator' ] -> findResource ( "config://{$type}.yaml" ) ) ; $ obj = new Data ( $ groups , $ blueprint ) ; $ obj -> file ( $ filename ) ; $ obj -> save ( ) ; return true ; }
docstring: Remove a group
  
  @param string $groupname
  
  @return bool True if the action was performed
docstring_tokens: Remove a group