summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/comment.module2
-rw-r--r--modules/comment/comment.module2
2 files changed, 2 insertions, 2 deletions
diff --git a/modules/comment.module b/modules/comment.module
index 13fedb752..50478287e 100644
--- a/modules/comment.module
+++ b/modules/comment.module
@@ -1141,7 +1141,7 @@ function comment_validate($edit) {
}
// Validate the comment's body.
- if ($edit['comment'] == '') {
+ if (trim($edit['comment']) == '') {
form_set_error('comment', t('The body of your comment is empty.'));
}
diff --git a/modules/comment/comment.module b/modules/comment/comment.module
index 13fedb752..50478287e 100644
--- a/modules/comment/comment.module
+++ b/modules/comment/comment.module
@@ -1141,7 +1141,7 @@ function comment_validate($edit) {
}
// Validate the comment's body.
- if ($edit['comment'] == '') {
+ if (trim($edit['comment']) == '') {
form_set_error('comment', t('The body of your comment is empty.'));
}