GhostManager / Ghostwriter

The SpecterOps project management and reporting engine
https://ghostwriter.wiki
BSD 3-Clause "New" or "Revised" License
1.23k stars 174 forks source link

Check if templated rich text fields are valid jinja2 #431

Closed ColonelThirtyTwo closed 1 month ago

ColonelThirtyTwo commented 1 month ago

Since rich text fields are now processed with jinja2, this patch checks them when saved to ensure they are valid jinja2 templates, and raises a validation error if they aren't.

Also fixes an issue with the error toasts that appear when attempting to save a field that failed validation.