aboutsummaryrefslogtreecommitdiffstats
path: root/include/items.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-04-03 15:55:22 -0700
committerzotlabs <mike@macgirvin.com>2017-04-03 15:55:22 -0700
commitf2f2b534e611c37105b1dc56470735c13641c944 (patch)
tree2eed3379df931bccd56dd7be8e3a56394fa3e0f9 /include/items.php
parent2d9ae8ff2c581b8981c9c7308c4cf98bfee934b1 (diff)
parenta9bda2b12e3d393fa854e23207a081052e2e7bfd (diff)
downloadvolse-hubzilla-f2f2b534e611c37105b1dc56470735c13641c944.tar.gz
volse-hubzilla-f2f2b534e611c37105b1dc56470735c13641c944.tar.bz2
volse-hubzilla-f2f2b534e611c37105b1dc56470735c13641c944.zip
Merge branch 'dev' of https://github.com/redmatrix/hubzilla into dev_merge
Diffstat (limited to 'include/items.php')
-rwxr-xr-xinclude/items.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/include/items.php b/include/items.php
index 304a7acfc..933b9ef81 100755
--- a/include/items.php
+++ b/include/items.php
@@ -769,6 +769,8 @@ function import_author_xchan($x) {
if($arr['xchan_hash'])
return $arr['xchan_hash'];
+ $y = false;
+
if((! array_key_exists('network', $x)) || ($x['network'] === 'zot')) {
$y = import_author_zot($x);
}
@@ -779,11 +781,11 @@ function import_author_xchan($x) {
$y = import_author_rss($x);
}
- if($x['network'] === 'unknown') {
+ if(! $y) {
$y = import_author_unknown($x);
}
- return(($y) ? $y : false);
+ return($y);
}
/**
@@ -1824,9 +1826,12 @@ logger('revision: ' . $arr['revision']);
intval($arr['revision'])
);
- if($r && count($r)) {
+ if($r) {
+ // This will gives us a fresh copy of what's now in the DB and undo the db escaping,
+ // which really messes up the notifications
+
$current_post = $r[0]['id'];
- $arr = $r[0]; // This will gives us a fresh copy of what's now in the DB and undo the db escaping, which really messes up the notifications
+ $arr = $r[0];
logger('item_store: created item ' . $current_post, LOGGER_DEBUG);
}
else {