From 72f00d6e04f0f57fc19f343a88975680baf8958a Mon Sep 17 00:00:00 2001 From: friendica Date: Sun, 15 Jun 2014 18:58:02 -0700 Subject: issues with editing webpage permissions --- assets/home.html | 6 +++--- include/items.php | 6 ++++-- mod/item.php | 10 ++++++++-- 3 files changed, 15 insertions(+), 7 deletions(-) diff --git a/assets/home.html b/assets/home.html index 9789209ef..4e8c9d67a 100644 --- a/assets/home.html +++ b/assets/home.html @@ -92,8 +92,8 @@ var r = 0; var g = 0; var b = 0; -var speed = 10; -var delay = 150; +var speed = 5; +var delay = 250; var timer = null; var holdid = 0; @@ -160,7 +160,7 @@ $(document).ready(function() {
- +
RedMatrix
The RedMatrix (aka "red") is an open source webapp providing a complete decentralised publishing, sharing, and communications system. It combines communications (private messaging, chat and social networking), and media management (photos, events, files, web pages, shareable apps) with enough features to make your head spin. diff --git a/include/items.php b/include/items.php index 434417751..275f5c05c 100755 --- a/include/items.php +++ b/include/items.php @@ -2001,8 +2001,6 @@ function item_store_update($arr,$allow_exec = false) { $arr = $d['item']; $allow_exec = $d['allow_exec']; - - $ret = array('success' => false, 'item_id' => 0); if(! intval($arr['uid'])) { logger('item_store_update: no uid'); @@ -2036,6 +2034,10 @@ function item_store_update($arr,$allow_exec = false) { if($orig[0]['item_flags'] & ITEM_VERIFIED) $orig[0]['item_flags'] = $orig[0]['item_flags'] ^ ITEM_VERIFIED; + if($orig[0]['item_flags'] & ITEM_OBSCURED) + $orig[0]['item_flags'] = $orig[0]['item_flags'] ^ ITEM_OBSCURED; + + $arr['item_flags'] = intval($arr['item_flags']) | $orig[0]['item_flags']; $arr['item_restrict'] = intval($arr['item_restrict']) | $orig[0]['item_restrict']; diff --git a/mod/item.php b/mod/item.php index d32c4dcac..d4c8a6f4a 100644 --- a/mod/item.php +++ b/mod/item.php @@ -280,11 +280,10 @@ function item_post(&$a) { if((strlen($str_group_allow)) || strlen($str_contact_allow) || strlen($str_group_deny) - || strlen(str_contact_deny)) { + || strlen($str_contact_deny)) { $private = 1; } - $location = $orig_post['location']; $coord = $orig_post['coord']; $verb = $orig_post['verb']; @@ -292,12 +291,19 @@ function item_post(&$a) { $title = $_REQUEST['title']; $body = $_REQUEST['body']; $item_flags = $orig_post['item_flags']; + + // force us to recalculate if we need to obscure this post + + if($item_flags & ITEM_OBSCURED) + $item_flags = ($item_flags ^ ITEM_OBSCURED); + $item_restrict = $orig_post['item_restrict']; $postopts = $orig_post['postopts']; $created = $orig_post['created']; $mid = $orig_post['mid']; $parent_mid = $orig_post['parent_mid']; $plink = $orig_post['plink']; + } else { -- cgit v1.2.3