MCPcopy
hub / github.com/IceWhaleTech/CasaOS / GetDirPathOne

Method GetDirPathOne

service/system.go:271–282  ·  view source on GitHub ↗
(path string)

Source from the content-addressed store, hash-verified

269}
270
271func (c *systemService) GetDirPathOne(path string) (m model.Path) {
272 f, err := os.Stat(path)
273 if err != nil {
274 return
275 }
276 m.IsDir = f.IsDir()
277 m.Name = f.Name()
278 m.Path = path
279 m.Size = f.Size()
280 m.Date = f.ModTime()
281 return
282}
283
284func (c *systemService) GetDirPath(path string) ([]model.Path, error) {
285 if path == "/DATA" {

Callers

nothing calls this directly

Calls 2

IsDirMethod · 0.65
ModTimeMethod · 0.65

Tested by

no test coverage detected