Avoid "array_merge" warning.

This commit is contained in:
Michael Vogel 2016-02-18 07:41:08 +01:00
parent fb28713ca3
commit 9619829b4a

View file

@ -438,6 +438,7 @@ function poco_last_updated($profile, $force = false) {
$noscrape = json_decode($noscraperet["body"], true); $noscrape = json_decode($noscraperet["body"], true);
if (is_array($noscrape)) {
$contact = array("url" => $profile, $contact = array("url" => $profile,
"network" => $server[0]["network"], "network" => $server[0]["network"],
"generation" => $gcontacts[0]["generation"]); "generation" => $gcontacts[0]["generation"]);
@ -473,12 +474,14 @@ function poco_last_updated($profile, $force = false) {
unset($noscrape["dfrn-poll"]); unset($noscrape["dfrn-poll"]);
$contact = array_merge($contact, $noscrape); $contact = array_merge($contact, $noscrape);
update_gcontact($contact); update_gcontact($contact);
return $noscrape["updated"]; return $noscrape["updated"];
} }
} }
} }
}
// If we only can poll the feed, then we only do this once a while // If we only can poll the feed, then we only do this once a while
if (!$force AND !poco_do_update($gcontacts[0]["created"], $gcontacts[0]["updated"], $gcontacts[0]["last_failure"], $gcontacts[0]["last_contact"])) if (!$force AND !poco_do_update($gcontacts[0]["created"], $gcontacts[0]["updated"], $gcontacts[0]["last_failure"], $gcontacts[0]["last_contact"]))