MCPcopy
hub / github.com/HelloZeroNet/ZeroNet / actionSiteList

Method actionSiteList

src/Ui/UiWebsocket.py:876–883  ·  view source on GitHub ↗
(self, to, connecting_sites=False)

Source from the content-addressed store, hash-verified

874 # List all site info
875 @flag.admin
876 def actionSiteList(self, to, connecting_sites=False):
877 ret = []
878 SiteManager.site_manager.load() # Reload sites
879 for site in list(self.server.sites.values()):
880 if not site.content_manager.contents.get("content.json") and not connecting_sites:
881 continue # Incomplete site
882 ret.append(self.formatSiteInfo(site, create_user=False)) # Dont generate the auth_address on listing
883 self.response(to, ret)
884
885 # Join to an event channel on all sites
886 @flag.admin

Callers

nothing calls this directly

Calls 5

formatSiteInfoMethod · 0.95
responseMethod · 0.95
valuesMethod · 0.80
loadMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected