Commit a7ee84fc authored by Michael Yang's avatar Michael Yang
Browse files

routes: skip invalid filepaths

parent 5cde17a0
......@@ -732,6 +732,11 @@ func (s *Server) ListModelsHandler(c *gin.Context) {
}
n := model.ParseNameFromFilepath(rel)
if !n.IsValid() {
slog.Info("invalid model filepath", "path", rel)
return nil
}
m, err := ParseNamedManifest(n)
if err != nil {
return err
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment