$root->appendChild($entry);
}
- return(trim($doc->saveXML()));
+ return trim($doc->saveXML());
}
/**
//$sql_extra .= file_tag_file_query('item',$category,'category');
}
- if ($public_feed) {
- if (! $converse) {
- $sql_extra .= " AND `contact`.`self` = 1 ";
- }
+ if ($public_feed && ! $converse) {
+ $sql_extra .= " AND `contact`.`self` = 1 ";
}
$check_date = DateTimeFormat::utc($last_update);
$root->appendChild($mail);
- return(trim($doc->saveXML()));
+ return trim($doc->saveXML());
}
/**
$root->appendChild($suggest);
- return(trim($doc->saveXML()));
+ return trim($doc->saveXML());
}
/**
$root->appendChild($relocate);
- return(trim($doc->saveXML()));
+ return trim($doc->saveXML());
}
/**
$htmlbody = $body;
if ($item['title'] != "") {
- $htmlbody = "[b]".$item['title']."[/b]\n\n".$htmlbody;
+ $htmlbody = "[b]" . $item['title'] . "[/b]\n\n" . $htmlbody;
}
$htmlbody = BBCode::convert($htmlbody, false, 7);
$tags = Item::getFeedTags($item);
+ /// @TODO Combine this with similar below if() block?
if (count($tags)) {
foreach ($tags as $t) {
if (($type != 'html') || ($t[0] != "@")) {
// Until now we aren't serving different sizes - but maybe later
$avatarlist = [];
/// @todo check if "avatar" or "photo" would be the best field in the specification
- $avatars = $xpath->query($element."/atom:link[@rel='avatar']", $context);
+ $avatars = $xpath->query($element . "/atom:link[@rel='avatar']", $context);
foreach ($avatars as $avatar) {
$href = "";
$width = 0;
$avatarlist[$width] = $href;
}
}
+
if (count($avatarlist) > 0) {
krsort($avatarlist);
$author["avatar"] = current($avatarlist);
if (self::updateContent($current, $item, $importer, $entrytype)) {
logger("Item ".$item["uri"]." was updated.", LOGGER_DEBUG);
} else {
- logger("Item ".$item["uri"]." already existed.", LOGGER_DEBUG);
+ logger("Item " . $item["uri"] . " already existed.", LOGGER_DEBUG);
}
return;
}