Fix multilingual reload when shortcode changes

This commit also refines the partial rebuild logic, to make sure we do not do more work than needed.

Updates #2309
This commit is contained in:
Bjørn Erik Pedersen
2016-08-13 00:33:17 +02:00
parent a823b1572b
commit b3563b40a4
6 changed files with 135 additions and 74 deletions

View File

@@ -281,10 +281,6 @@ func renderShortcode(sc shortcode, parent *ShortcodeWithPage, p *Page, t tpl.Tem
func extractAndRenderShortcodes(stringToParse string, p *Page, t tpl.Template) (string, map[string]func() (string, error), error) {
if p.rendered {
panic("Illegal state: Page already marked as rendered, please reuse the shortcodes")
}
content, shortcodes, err := extractShortcodes(stringToParse, p, t)
if err != nil {