Skip to content

Commit

Permalink
fix spelling
Browse files Browse the repository at this point in the history
  • Loading branch information
gphorvath committed Nov 2, 2024
1 parent 8f7a249 commit 9ee407d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions internal/prompt/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ func (m *Manager) Load(name string) (*Prompt, error) {
return nil, fmt.Errorf("failed to read prompt file: %w", err)
}

// Split frontmatter and content
// Split front matter and content
parts := strings.Split(string(content), "---\n")
if len(parts) < 3 {
return nil, fmt.Errorf("invalid prompt format: missing frontmatter")
return nil, fmt.Errorf("invalid prompt format: missing front matter")
}

var metadata Metadata
if err := yaml.Unmarshal([]byte(parts[1]), &metadata); err != nil {
return nil, fmt.Errorf("failed to parse frontmatter: %w", err)
return nil, fmt.Errorf("failed to parse front matter: %w", err)
}

fileInfo, err := os.Stat(path)
Expand Down

0 comments on commit 9ee407d

Please sign in to comment.