MCPcopy Create free account
hub / github.com/aaPanel/BaoTa / remove_group

Method remove_group

mod/project/php/php_asyncMod.py:1649–1657  ·  view source on GitHub ↗
(self, get)

Source from the content-addressed store, hash-verified

1647 return public.returnResult(False, traceback.format_exc())
1648
1649 def remove_group(self, get):
1650 if not hasattr(get, 'group_name'):
1651 return public.returnResult(False, '组名不能为空')
1652 config = self.get_group_file()
1653 if get.group_name not in config:
1654 return public.returnResult(False, '组名不存在')
1655 del config[get.group_name]
1656 public.writeFile(self.group_file, json.dumps(config))
1657 return public.returnResult(True, '删除成功')
1658
1659 def group_add_project(self, get):
1660 try:

Callers

nothing calls this directly

Calls 4

get_group_fileMethod · 0.95
returnResultMethod · 0.80
writeFileMethod · 0.80
dumpsMethod · 0.45

Tested by

no test coverage detected