]> git.mxchange.org Git - friendica.git/commitdiff
Merge pull request #6412 from annando/issue-6149
authorHypolite Petovan <hypolite@mrpetovan.com>
Tue, 8 Jan 2019 14:17:05 +0000 (09:17 -0500)
committerGitHub <noreply@github.com>
Tue, 8 Jan 2019 14:17:05 +0000 (09:17 -0500)
Issue 6149: Making OWA (hopefully) compatible with Hubzilla

mod/xrd.php
src/Module/Magic.php
src/Module/Owa.php
view/templates/xrd_person.tpl

index 4b9b0ee8fb4e1931848b799cb07d5a86ec6b2dc7..1611540a6c4955990beb48644f7c1851adb7abd2 100644 (file)
@@ -92,7 +92,7 @@ function xrd_json($a, $uri, $alias, $profile_url, $r)
                        ['rel' => 'http://salmon-protocol.org/ns/salmon-mention', 'href' => System::baseUrl().'/salmon/'.$r['nickname'].'/mention'],
                        ['rel' => 'http://ostatus.org/schema/1.0/subscribe', 'template' => System::baseUrl().'/follow?url={uri}'],
                        ['rel' => 'magic-public-key', 'href' => 'data:application/magic-public-key,'.$salmon_key],
-                       ['rel' => 'http://purl.org/openwebauth/v1', 'type' => 'application/x-dfrn+json', 'href' => System::baseUrl().'/owa']
+                       ['rel' => 'http://purl.org/openwebauth/v1', 'type' => 'application/x-zot+json', 'href' => System::baseUrl().'/owa']
                ]
        ];
 
index f0be114e3dbb056aa1c46897360d3e4ef1158d3d..491ed31cbd4a4bd0c24036ea45a398325d078251 100644 (file)
@@ -74,7 +74,7 @@ class Magic extends BaseModule
                                $basepath = $exp[0];
 
                                $headers = [];
-                               $headers['Accept'] = 'application/x-dfrn+json';
+                               $headers['Accept'] = 'application/x-dfrn+json, application/x-zot+json';
                                $headers['X-Open-Web-Auth'] = Strings::getRandomHex();
 
                                // Create a header that is signed with the local users private key.
index bfe108c842c0e62f982a1b4c99f828cedaa387a6..7243c111344b4d159e5fa6d5a86b701936ecd241 100644 (file)
@@ -86,6 +86,6 @@ class Owa extends BaseModule
                                }
                        }
                }
-               System::jsonExit($ret, 'application/x-dfrn+json');
+               System::jsonExit($ret, 'application/x-zot+json');
        }
 }
index aa402b1a8fcd8ec31715e8fc91814d608a55409a..578698b46b9a479265e8a1985f6c2ca3e770867c 100644 (file)
@@ -34,6 +34,6 @@
     <Link rel="magic-public-key" 
           href="{{$modexp}}" />
     <Link rel="http://purl.org/openwebauth/v1"
-          type="application/x-dfrn+json"
+          type="application/x-zot+json"
           href="{{$openwebauth}}" />
 </XRD>