aboutsummaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorJoey Hess <joey@kitenet.net>2011-07-11 18:34:17 -0400
committerJoey Hess <joey@kitenet.net>2011-07-11 18:34:17 -0400
commit258b75c4f787ec2709a1cb089f839333cbf4f071 (patch)
tree86afb37356d5cdb5150132e3797312ae2a84380c /IkiWiki
parent45a058a2c7e30f4517950ac60f11efc10cc03361 (diff)
downloadikiwiki-258b75c4f787ec2709a1cb089f839333cbf4f071.tar
ikiwiki-258b75c4f787ec2709a1cb089f839333cbf4f071.tar.gz
attachment: Bugfix to move upload attachments out of holding area when saving.
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/Plugin/attachment.pm7
1 files changed, 4 insertions, 3 deletions
diff --git a/IkiWiki/Plugin/attachment.pm b/IkiWiki/Plugin/attachment.pm
index 52bac7c1e..d8e2f6271 100644
--- a/IkiWiki/Plugin/attachment.pm
+++ b/IkiWiki/Plugin/attachment.pm
@@ -116,9 +116,10 @@ sub formbuilder_setup (@) {
$form->tmpl_param("attachments-class" => "toggleable-open");
}
- # Save attachments in holding area before previewing so
- # they can be seen in the preview.
- if ($form->submitted eq "Preview") {
+ # Save attachments in holding area before previewing and
+ # saving.
+ if ($form->submitted eq "Preview" ||
+ $form->submitted eq "Save Page") {
attachments_save($form, $params{session});
}
}