mirror of
https://github.com/friendica/friendica
synced 2025-05-04 00:24:16 +02: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\Network;
|
||||
|
||||
use Friendica\Core\Addon;
|
||||
use Friendica\Core\Logger;
|
||||
use Friendica\Core\PConfig;
|
||||
use Friendica\Core\System;
|
||||
use Friendica\Database\DBA;
|
||||
|
@ -34,12 +35,12 @@ class FKOAuth1 extends OAuthServer
|
|||
*/
|
||||
public function loginUser($uid)
|
||||
{
|
||||
logger("FKOAuth1::loginUser $uid");
|
||||
Logger::log("FKOAuth1::loginUser $uid");
|
||||
$a = get_app();
|
||||
$record = DBA::selectFirst('user', [], ['uid' => $uid, 'blocked' => 0, 'account_expired' => 0, 'account_removed' => 0, 'verified' => 1]);
|
||||
|
||||
if (!DBA::isResult($record)) {
|
||||
logger('FKOAuth1::loginUser failure: ' . print_r($_SERVER, true), LOGGER_DEBUG);
|
||||
Logger::log('FKOAuth1::loginUser failure: ' . print_r($_SERVER, true), LOGGER_DEBUG);
|
||||
header('HTTP/1.0 401 Unauthorized');
|
||||
die('This api requires login');
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue