MCPcopy Create free account
hub / github.com/devld/go-drive / savePathMeta

Method savePathMeta

server/api_admin_config.go:62–74  ·  view source on GitHub ↗
(c *gin.Context)

Source from the content-addressed store, hash-verified

60}
61
62func (cr *configRoute) savePathMeta(c *gin.Context) {
63 path := utils.CleanPath(c.Param("path"))
64 data := types.PathMeta{}
65 if e := c.Bind(&data); e != nil {
66 _ = c.Error(e)
67 return
68 }
69 data.Path = &path
70 if e := cr.pathMetaDAO.Set(data); e != nil {
71 _ = c.Error(e)
72 return
73 }
74}
75
76func (cr *configRoute) deletePathMeta(c *gin.Context) {
77 path := utils.CleanPath(c.Param("path"))

Callers

nothing calls this directly

Calls 3

CleanPathFunction · 0.92
ErrorMethod · 0.65
SetMethod · 0.45

Tested by

no test coverage detected