]> git.mxchange.org Git - friendica.git/commitdiff
"networks" has to contain all probing fields
authorMichael <heluecht@pirati.ca>
Sat, 10 Dec 2022 12:35:05 +0000 (12:35 +0000)
committerMichael <heluecht@pirati.ca>
Sat, 10 Dec 2022 12:35:05 +0000 (12:35 +0000)
src/Network/Probe.php

index a97f6f8110cd74840eff19ca3aca65bddc3fc4c2..e74b4373454b4403ef0d275a6c047ce9b6de169f 100644 (file)
@@ -137,7 +137,11 @@ class Probe
                $newdata['networks'] = [];
                foreach ([Protocol::DIASPORA, Protocol::OSTATUS] as $network) {
                        if (!empty($data['networks'][$network])) {
-                               $newdata['networks'][$network] = $data['networks'][$network];
+                               $data['networks'][$network]['subscribe'] = $newdata['subscribe'] ?? '';
+                               $data['networks'][$network]['baseurl'] = $newdata['baseurl'] ?? '';
+                               $data['networks'][$network]['gsid'] = $newdata['gsid'] ?? 0;
+                               $newdata['networks'][$network] = self::rearrangeData($data['networks'][$network]);
+                               unset($newdata['networks'][$network]['networks']);
                        }
                }