aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Item.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-01-17 17:41:19 -0800
committerzotlabs <mike@macgirvin.com>2017-01-17 17:41:19 -0800
commitb6595a44d1f6db38c104abaa3c24f42223316ec5 (patch)
tree93e3ad19a3b6cbae4d375b71ad8481892f6b1001 /Zotlabs/Module/Item.php
parent335d9af8dc4b02f8ec4017d30525a65e93c40eb2 (diff)
downloadvolse-hubzilla-b6595a44d1f6db38c104abaa3c24f42223316ec5.tar.gz
volse-hubzilla-b6595a44d1f6db38c104abaa3c24f42223316ec5.tar.bz2
volse-hubzilla-b6595a44d1f6db38c104abaa3c24f42223316ec5.zip
native wiki stuff
Diffstat (limited to 'Zotlabs/Module/Item.php')
-rw-r--r--Zotlabs/Module/Item.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/Zotlabs/Module/Item.php b/Zotlabs/Module/Item.php
index 13d0cf8c6..91a8b1a47 100644
--- a/Zotlabs/Module/Item.php
+++ b/Zotlabs/Module/Item.php
@@ -429,7 +429,9 @@ class Item extends \Zotlabs\Web\Controller {
$body = trim($_REQUEST['body']);
$body .= trim($_REQUEST['attachment']);
$postopts = '';
-
+
+ $allow_empty = ((array_key_exists('allow_empty',$_REQUEST)) ? intval($_REQUEST['allow_empty']) : 0);
+
$private = intval($acl->is_private() || ($public_policy));
// If this is a comment, set the permissions from the parent.
@@ -442,7 +444,7 @@ class Item extends \Zotlabs\Web\Controller {
$owner_hash = $parent_item['owner_xchan'];
}
- if(! strlen($body)) {
+ if((! $allow_empty) && (! strlen($body))) {
if($preview)
killme();
info( t('Empty post discarded.') . EOL );