summaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorJoey Hess <joey@kodama.kitenet.net>2008-02-03 19:51:00 -0500
committerJoey Hess <joey@kodama.kitenet.net>2008-02-03 19:51:00 -0500
commita3f224cb6cf82b89cf0cbadbd661fd5d71ebf8ae (patch)
tree2895c92572ddd599acd4580b7caf62a798876556 /IkiWiki
parent408419ca3e76aa629222af81694042c2fb02d8ec (diff)
move saveindex call into preview block
This call is only present to handle the case where previewing a page actually causes files to be rendered.
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/CGI.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/IkiWiki/CGI.pm b/IkiWiki/CGI.pm
index 1ec23df68..4d4464c28 100644
--- a/IkiWiki/CGI.pm
+++ b/IkiWiki/CGI.pm
@@ -357,6 +357,8 @@ sub cgi_editpage ($$) { #{{{
linkify($page, "",
preprocess($page, $page,
filter($page, $page, $content), 0, 1))));
+ # previewing may have created files on disk
+ saveindex();
}
elsif ($form->submitted eq "Save Page") {
$form->tmpl_param("page_preview", "");
@@ -448,7 +450,6 @@ sub cgi_editpage ($$) { #{{{
}
showform($form, \@buttons, $session, $q);
- saveindex();
}
else {
# save page