mirror of
https://github.com/friendica/friendica
synced 2025-04-19 11:10:10 +00:00
Log function
implement log() function.
This commit is contained in:
parent
d6d593d724
commit
14fde5dc9b
122 changed files with 1280 additions and 1161 deletions
|
@ -5,6 +5,7 @@
|
|||
namespace Friendica\Module;
|
||||
|
||||
use Friendica\BaseModule;
|
||||
use Friendica\Core\Logger;
|
||||
use Friendica\Core\System;
|
||||
use Friendica\Database\DBA;
|
||||
use Friendica\Model\Contact;
|
||||
|
@ -57,8 +58,8 @@ class Owa extends BaseModule
|
|||
$verified = HTTPSignature::verifyMagic($contact['pubkey']);
|
||||
|
||||
if ($verified && $verified['header_signed'] && $verified['header_valid']) {
|
||||
logger('OWA header: ' . print_r($verified, true), LOGGER_DATA);
|
||||
logger('OWA success: ' . $contact['addr'], LOGGER_DATA);
|
||||
Logger::log('OWA header: ' . print_r($verified, true), LOGGER_DATA);
|
||||
Logger::log('OWA success: ' . $contact['addr'], LOGGER_DATA);
|
||||
|
||||
$ret['success'] = true;
|
||||
$token = random_string(32);
|
||||
|
@ -75,10 +76,10 @@ class Owa extends BaseModule
|
|||
openssl_public_encrypt($token, $result, $contact['pubkey']);
|
||||
$ret['encrypted_token'] = base64url_encode($result);
|
||||
} else {
|
||||
logger('OWA fail: ' . $contact['id'] . ' ' . $contact['addr'] . ' ' . $contact['url'], LOGGER_DEBUG);
|
||||
Logger::log('OWA fail: ' . $contact['id'] . ' ' . $contact['addr'] . ' ' . $contact['url'], LOGGER_DEBUG);
|
||||
}
|
||||
} else {
|
||||
logger('Contact not found: ' . $handle, LOGGER_DEBUG);
|
||||
Logger::log('Contact not found: ' . $handle, LOGGER_DEBUG);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue