MCPcopy Index your code
hub / github.com/ZenNotes/zennotes / listAssets

Method listAssets

apps/server/internal/httpserver/server.go:513–520  ·  view source on GitHub ↗
(w http.ResponseWriter, _ *http.Request)

Source from the content-addressed store, hash-verified

511}
512
513func (s *Server) listAssets(w http.ResponseWriter, _ *http.Request) {
514 assets, err := s.currentVault().ListAssets()
515 if err != nil {
516 writeError(w, err)
517 return
518 }
519 writeJSON(w, http.StatusOK, assets)
520}
521
522func (s *Server) assetsExists(w http.ResponseWriter, _ *http.Request) {
523 writeJSON(w, http.StatusOK, map[string]bool{"exists": s.currentVault().HasAssetsDir()})

Callers

nothing calls this directly

Calls 4

currentVaultMethod · 0.95
writeErrorFunction · 0.85
writeJSONFunction · 0.85
ListAssetsMethod · 0.80

Tested by

no test coverage detected