$subscribe = (($hub_mode === 'subscribe') ? 1 : 0);
$owner = DBA::selectFirst('user', ['uid'], ['nickname' => $nick, 'account_expired' => false, 'account_removed' => false]);
- if (!DBA::is_result($owner)) {
+ if (!DBA::isResult($owner)) {
logger('Local account not found: ' . $nick);
hub_return(false, '');
}
}
$contact = DBA::selectFirst('contact', ['id', 'poll'], $condition);
- if (!DBA::is_result($contact)) {
+ if (!DBA::isResult($contact)) {
logger('Contact ' . $contact_id . ' not found.');
hub_return(false, '');
}
$contact_id = (($a->argc > 2) ? intval($a->argv[2]) : 0 );
$importer = DBA::selectFirst('user', [], ['nickname' => $nick, 'account_expired' => false, 'account_removed' => false]);
- if (!DBA::is_result($importer)) {
+ if (!DBA::isResult($importer)) {
hub_post_return();
}
$condition = ['id' => $contact_id, 'uid' => $importer['uid'], 'subhub' => true, 'blocked' => false];
$contact = DBA::selectFirst('contact', [], $condition);
- if (!DBA::is_result($contact)) {
+ if (!DBA::isResult($contact)) {
$author = OStatus::salmonAuthor($xml, $importer);
if (!empty($author['contact-id'])) {
$condition = ['id' => $author['contact-id'], 'uid' => $importer['uid'], 'subhub' => true, 'blocked' => false];
$contact = DBA::selectFirst('contact', [], $condition);
logger('No record for ' . $nick .' with contact id ' . $contact_id . ' - using '.$author['contact-id'].' instead.');
}
- if (!DBA::is_result($contact)) {
+ if (!DBA::isResult($contact)) {
logger('Contact ' . $author["author-link"] . ' (' . $contact_id . ') for user ' . $nick . " wasn't found - ignored. XML: " . $xml);
hub_post_return();
}