mirror of
https://github.com/friendica/friendica
synced 2024-11-10 03:42:53 +00:00
Merge pull request #13709 from friendica/MrPetovan-patch-1
Add support for string in $nodeinfo['protocols']
This commit is contained in:
commit
2643ca11e6
1 changed files with 14 additions and 6 deletions
|
@ -1266,9 +1266,13 @@ class GServer
|
|||
|
||||
if (!empty($nodeinfo['protocols'])) {
|
||||
$protocols = [];
|
||||
foreach ($nodeinfo['protocols'] as $protocol) {
|
||||
if (is_string($protocol)) {
|
||||
$protocols[$protocol] = true;
|
||||
if (is_string($nodeinfo['protocols'])) {
|
||||
$protocols[$nodeinfo['protocols']] = true;
|
||||
} else {
|
||||
foreach ($nodeinfo['protocols'] as $protocol) {
|
||||
if (is_string($protocol)) {
|
||||
$protocols[$protocol] = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1367,9 +1371,13 @@ class GServer
|
|||
|
||||
if (!empty($nodeinfo['protocols'])) {
|
||||
$protocols = [];
|
||||
foreach ($nodeinfo['protocols'] as $protocol) {
|
||||
if (is_string($protocol)) {
|
||||
$protocols[$protocol] = true;
|
||||
if (is_string($nodeinfo['protocols'])) {
|
||||
$protocols[$nodeinfo['protocols']] = true;
|
||||
} else {
|
||||
foreach ($nodeinfo['protocols'] as $protocol) {
|
||||
if (is_string($protocol)) {
|
||||
$protocols[$protocol] = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue