X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=mod%2Fdfrn_notify.php;h=2e1f51a11c056344c20041035165554fe2875086;hb=8293d5ed0af78ae6cc5629bb1f982a7b29794d32;hp=3d27593aaf51a6c93f93c01aa128b32364cc6166;hpb=771637459389d725ecb11e848740dce0f456418b;p=friendica.git diff --git a/mod/dfrn_notify.php b/mod/dfrn_notify.php index 3d27593aaf..2e1f51a11c 100644 --- a/mod/dfrn_notify.php +++ b/mod/dfrn_notify.php @@ -1,16 +1,32 @@ . + * + * The dfrn notify endpoint + * * @see PDF with dfrn specs: https://github.com/friendica/friendica/blob/master/spec/dfrn2.pdf */ use Friendica\App; -use Friendica\Core\Config; use Friendica\Core\Logger; use Friendica\Core\System; use Friendica\Database\DBA; +use Friendica\DI; use Friendica\Model\Contact; use Friendica\Model\User; use Friendica\Protocol\DFRN; @@ -128,7 +144,7 @@ function dfrn_notify_post(App $a) { System::xmlExit(0, 'relationship dissolved'); } - $rino = Config::get('system', 'rino_encrypt'); + $rino = DI::config()->get('system', 'rino_encrypt'); $rino = intval($rino); if (strlen($key)) { @@ -214,7 +230,7 @@ function dfrn_dispatch_public($postdata) function dfrn_dispatch_private($user, $postdata) { - $msg = Diaspora::decodeRaw($postdata, $user); + $msg = Diaspora::decodeRaw($postdata, $user['prvkey'] ?? ''); if (!$msg) { System::xmlExit(4, 'Unable to parse message'); } @@ -343,7 +359,7 @@ function dfrn_notify_content(App $a) { $encrypted_id = bin2hex($encrypted_id); - $rino = Config::get('system', 'rino_encrypt'); + $rino = DI::config()->get('system', 'rino_encrypt'); $rino = intval($rino); Logger::log("Local rino version: ". $rino, Logger::DATA);