summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--IkiWiki/Plugin/comments.pm6
1 files changed, 4 insertions, 2 deletions
diff --git a/IkiWiki/Plugin/comments.pm b/IkiWiki/Plugin/comments.pm
index 6bd18a5cf..d1105b366 100644
--- a/IkiWiki/Plugin/comments.pm
+++ b/IkiWiki/Plugin/comments.pm
@@ -434,8 +434,10 @@ sub sessioncgi ($$) { #{{{
}
my $subject = $form->field('subject');
- $subject =~ s/"/"/g;
- $content .= " subject=\"$subject\"\n";
+ if (length $subject) {
+ $subject =~ s/"/"/g;
+ $content .= " subject=\"$subject\"\n";
+ }
$content .= " date=\"" . IkiWiki::formattime(time, '%X %x') . "\"\n";