forked from GNUsocial/gnu-social
Fix because qvitter supplies a twitter array value which is an array
works for json API, not for XML, so we make an exception here...
This commit is contained in:
parent
cf6e06a5dd
commit
fe328ae5e4
@ -651,6 +651,11 @@ class ApiAction extends Action
|
||||
break;
|
||||
default:
|
||||
if (strncmp($element, 'statusnet_', 10) == 0) {
|
||||
if ($element === 'statusnet_in_groups' && is_array($value)) {
|
||||
// QVITTERFIX because it would cause an array to be sent as $value
|
||||
// THIS IS UNDOCUMENTED AND SHOULD NEVER BE RELIED UPON (qvitter uses json output)
|
||||
$value = json_encode($value);
|
||||
}
|
||||
$this->element('statusnet:'.substr($element, 10), null, $value);
|
||||
} else {
|
||||
$this->element($element, null, $value);
|
||||
|
Loading…
Reference in New Issue
Block a user