aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/comanche.php2
-rw-r--r--include/conversation.php5
-rwxr-xr-xinclude/items.php12
-rw-r--r--include/notifier.php22
-rw-r--r--include/socgraph.php2
5 files changed, 30 insertions, 13 deletions
diff --git a/include/comanche.php b/include/comanche.php
index e0d3af985..c1a98ed6c 100644
--- a/include/comanche.php
+++ b/include/comanche.php
@@ -155,7 +155,7 @@ function comanche_block($s) {
dbesc($name)
);
if($r) {
- $o .= (($var['wrap'] == 'none') ? '' : '<div class="bblock">');
+ $o .= (($var['wrap'] == 'none') ? '' : '<div class="bblock widget">');
if($r[0]['title'])
$o .= '<h3>' . $r[0]['title'] . '</h3>';
diff --git a/include/conversation.php b/include/conversation.php
index 0250ad8b9..fe48ed2f5 100644
--- a/include/conversation.php
+++ b/include/conversation.php
@@ -1086,6 +1086,8 @@ function status_editor($a, $x, $popup = false) {
// $plaintext = false;
$voting = feature_enabled(local_channel(), 'consensus_tools');
+ if(x($x, 'novoting'))
+ $voting = false;
$mimeselect = '';
if(array_key_exists('mimetype', $x) && $x['mimetype']) {
@@ -1190,7 +1192,8 @@ function status_editor($a, $x, $popup = false) {
'$noloc' => ((get_pconfig($x['profile_uid'], 'system', 'use_browser_location')) ? t('Clear browser location') : ''),
'$shortnoloc' => t('clear location'),
'$title' => ((x($x, 'title')) ? htmlspecialchars($x['title'], ENT_COMPAT,'UTF-8') : ''),
- '$placeholdertitle' => t('Title (optional)'),
+ '$placeholdertitle' => ((x($x, 'placeholdertitle')) ? $x['placeholdertitle'] : t('Title (optional)')),
+ '$hidetitle' => ((x($x, 'hidetitle')) ? $x['hidetitle'] : false),
'$catsenabled' => ((feature_enabled($x['profile_uid'], 'categories') && (! $webpage)) ? 'categories' : ''),
'$category' => "",
'$placeholdercategory' => t('Categories (optional, comma-separated list)'),
diff --git a/include/items.php b/include/items.php
index 1eb1a6446..98596cede 100755
--- a/include/items.php
+++ b/include/items.php
@@ -4409,7 +4409,7 @@ function zot_feed($uid,$observer_xchan,$arr) {
$limit = " LIMIT 100 ";
if($mindate != NULL_DATE) {
- $sql_extra .= " and ( created > '$mindate' or edited > '$mindate' ) ";
+ $sql_extra .= " and ( created > '$mindate' or changed > '$mindate' ) ";
}
if($message_id) {
@@ -4427,7 +4427,7 @@ function zot_feed($uid,$observer_xchan,$arr) {
if(is_sys_channel($uid)) {
require_once('include/security.php');
- $r = q("SELECT parent, created from item
+ $r = q("SELECT parent, created, postopts from item
WHERE uid != %d
and uid in (" . stream_perms_api_uids(PERMS_PUBLIC,10,1) . ") AND item_restrict = 0
AND item_wall = 1
@@ -4436,7 +4436,7 @@ function zot_feed($uid,$observer_xchan,$arr) {
);
}
else {
- $r = q("SELECT parent, created from item
+ $r = q("SELECT parent, created, postopts from item
WHERE uid = %d AND item_restrict = 0
AND item_wall = 1
$sql_extra GROUP BY parent ORDER BY created ASC $limit",
@@ -4445,6 +4445,12 @@ function zot_feed($uid,$observer_xchan,$arr) {
}
if($r) {
+ for($x = 0; $x < count($r); $x ++) {
+ if(strpos($r[$x]['postopts'],'nodeliver') !== false) {
+ unset($r[$x]);
+ }
+ }
+
$parents_str = ids_to_querystr($r,'parent');
$sys_query = ((is_sys_channel($uid)) ? $sql_extra : '');
diff --git a/include/notifier.php b/include/notifier.php
index 4ea1ffe35..4833e980c 100644
--- a/include/notifier.php
+++ b/include/notifier.php
@@ -350,6 +350,11 @@ function notifier_run($argv, $argc){
return;
}
+ if(strpos($target_item['postopts'],'nodeliver') !== false) {
+ logger('notifier: target item is undeliverable', LOGGER_DEBUG);
+ return;
+ }
+
$s = q("select * from channel where channel_id = %d limit 1",
intval($target_item['uid'])
);
@@ -374,6 +379,12 @@ function notifier_run($argv, $argc){
if(! $r)
return;
+
+ if(strpos($r[0]['postopts'],'nodeliver') !== false) {
+ logger('notifier: target item is undeliverable', LOGGER_DEBUG);
+ return;
+ }
+
xchan_query($r);
$r = fetch_post_tags($r);
@@ -585,16 +596,13 @@ function notifier_run($argv, $argc){
foreach($dhubs as $hub) {
- if(defined('DIASPORA_RELIABILITY_EMULATION')) {
- $cointoss = mt_rand(0,2);
- if($cointoss == 2) {
+ if($hub['hubloc_network'] === 'diaspora' || $hub['hubloc_network'] === 'friendica-over-diaspora') {
+ if(! get_config('system','diaspora_enabled'))
continue;
- }
- }
+ // allow this to be set per message
- if($hub['hubloc_network'] === 'diaspora' || $hub['hubloc_network'] === 'friendica-over-diaspora') {
- if(! get_config('system','diaspora_enabled'))
+ if(strpos($target_item['postopts'],'nodspr') !== false)
continue;
require_once('include/diaspora.php');
diff --git a/include/socgraph.php b/include/socgraph.php
index d8e2e1958..3e8bcc19e 100644
--- a/include/socgraph.php
+++ b/include/socgraph.php
@@ -466,7 +466,7 @@ function poco($a,$extended = false) {
$sql_extra = " and abook_flags = 0 ";
if($cid)
- $sql_extra = sprintf(" and abook_id = %d ",intval($cid));
+ $sql_extra = sprintf(" and abook_id = %d and ( abook_flags & " . ABOOK_FLAG_HIDDEN . " ) = 0 ",intval($cid));
if($system_mode) {
$r = q("SELECT count(*) as `total` from abook where ( abook_flags & " . ABOOK_FLAG_SELF .