aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2018-06-10 15:27:55 -0700
committerzotlabs <mike@macgirvin.com>2018-06-10 15:27:55 -0700
commit6959c9e42350b7d19402bef24bb4fd366af22ed4 (patch)
tree0e91ef5a681901847a3e52512aa17065f1031aa7
parent7bf1c5f27b8b8f0eea226e81a5db99585c5a56b3 (diff)
downloadvolse-hubzilla-6959c9e42350b7d19402bef24bb4fd366af22ed4.tar.gz
volse-hubzilla-6959c9e42350b7d19402bef24bb4fd366af22ed4.tar.bz2
volse-hubzilla-6959c9e42350b7d19402bef24bb4fd366af22ed4.zip
fixes for immediate expire, channel_active not initialised in DB
-rw-r--r--include/channel.php1
-rwxr-xr-xinclude/items.php5
2 files changed, 2 insertions, 4 deletions
diff --git a/include/channel.php b/include/channel.php
index 1a62dcd3c..d26056171 100644
--- a/include/channel.php
+++ b/include/channel.php
@@ -2359,6 +2359,7 @@ function channel_store_lowlevel($arr) {
'channel_dirdate' => ((array_key_exists('channel_dirdate',$arr)) ? $arr['channel_dirdate'] : NULL_DATE),
'channel_lastpost' => ((array_key_exists('channel_lastpost',$arr)) ? $arr['channel_lastpost'] : NULL_DATE),
'channel_deleted' => ((array_key_exists('channel_deleted',$arr)) ? $arr['channel_deleted'] : NULL_DATE),
+ 'channel_active' => ((array_key_exists('channel_active',$arr)) ? $arr['channel_active'] : NULL_DATE),
'channel_max_anon_mail' => ((array_key_exists('channel_max_anon_mail',$arr)) ? $arr['channel_max_anon_mail'] : '10'),
'channel_max_friend_req' => ((array_key_exists('channel_max_friend_req',$arr)) ? $arr['channel_max_friend_req'] : '10'),
'channel_expire_days' => ((array_key_exists('channel_expire_days',$arr)) ? $arr['channel_expire_days'] : '0'),
diff --git a/include/items.php b/include/items.php
index e75a9659d..54df5d322 100755
--- a/include/items.php
+++ b/include/items.php
@@ -3697,10 +3697,7 @@ function delete_item_lowlevel($item, $stage = DROPITEM_NORMAL, $force = false) {
);
}
else {
- $r = q("UPDATE item SET item_deleted = 1, body = '', title = '',
- changed = '%s', edited = '%s' WHERE id = %d",
- dbesc(datetime_convert()),
- dbesc(datetime_convert()),
+ $r = q("DELETE FROM item WHERE id = %d",
intval($item['id'])
);
}