]> git.mxchange.org Git - friendica.git/blobdiff - src/Module/Owa.php
Merge pull request #7848 from annando/mail-hooks
[friendica.git] / src / Module / Owa.php
index 8832dd9b0d12d6db823520fad86868be6682c272..ca4eec47ffad0f2cfd94624b15cd9d638ef47ac7 100644 (file)
@@ -27,7 +27,7 @@ use Friendica\Util\Strings;
  */
 class Owa extends BaseModule
 {
-       public static function init()
+       public static function init(array $parameters = [])
        {
 
                $ret = [ 'success' => false ];
@@ -75,7 +75,7 @@ class Owa extends BaseModule
                                                                // At a later time, we will compare weather the token we're getting
                                                                // is really the same token we have stored in the database.
                                                                openssl_public_encrypt($token, $result, $contact['pubkey']);
-                                                               $ret['encrypted_token'] = base64url_encode($result);
+                                                               $ret['encrypted_token'] = Strings::base64UrlEncode($result);
                                                        } else {
                                                                Logger::log('OWA fail: ' . $contact['id'] . ' ' . $contact['addr'] . ' ' . $contact['url'], Logger::DEBUG);
                                                        }
@@ -86,6 +86,6 @@ class Owa extends BaseModule
                                }
                        }
                }
-               System::jsonExit($ret, 'application/x-dfrn+json');
+               System::jsonExit($ret, 'application/x-zot+json');
        }
 }