Unverified Commit dd352ab2 authored by Patrick Devine's avatar Patrick Devine Committed by GitHub
Browse files

fix crash bug with /save when quotes are used (#8208)

parent d8bab8ea
......@@ -485,6 +485,9 @@ func buildModelfile(opts runOptions) string {
}
for _, msg := range opts.Messages {
if strings.Contains(msg.Content, "\"") {
msg.Content = `"""` + msg.Content + `"""`
}
f.Commands = append(f.Commands, parser.Command{Name: "message", Args: fmt.Sprintf("%s: %s", msg.Role, msg.Content)})
}
......
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