[API] Fix /api/statuses/update reporting a failure
This commit is contained in:
parent
9efbef720d
commit
4e02cb437a
|
@ -190,14 +190,14 @@ class ApiAction extends Action
|
||||||
*
|
*
|
||||||
* @param string $tag Element type or tagname
|
* @param string $tag Element type or tagname
|
||||||
* @param array|string|null $attrs Array of element attributes, as key-value pairs
|
* @param array|string|null $attrs Array of element attributes, as key-value pairs
|
||||||
* @param string|null $content string content of the element
|
* @param string|bool|null $content string content of the element
|
||||||
*
|
*
|
||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function element(string $tag, $attrs = null, ?string $content = null): void
|
public function element(string $tag, $attrs = null, $content = null): void
|
||||||
{
|
{
|
||||||
if (is_bool($content)) {
|
if (is_bool($content)) {
|
||||||
$content = ($content ? "true" : "false");
|
$content = ($content ? 'true' : 'false');
|
||||||
}
|
}
|
||||||
|
|
||||||
parent::element($tag, $attrs, $content);
|
parent::element($tag, $attrs, $content);
|
||||||
|
@ -512,6 +512,9 @@ class ApiAction extends Action
|
||||||
// FIXME: MOVE TO SHARE PLUGIN
|
// FIXME: MOVE TO SHARE PLUGIN
|
||||||
$this->showTwitterXmlStatus($value, 'retweeted_status');
|
$this->showTwitterXmlStatus($value, 'retweeted_status');
|
||||||
break;
|
break;
|
||||||
|
case 'tags':
|
||||||
|
// Used only for showTwitterRssItem
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
if (strncmp($element, 'statusnet_', 10) == 0) {
|
if (strncmp($element, 'statusnet_', 10) == 0) {
|
||||||
if ($element === 'statusnet_in_groups' && is_array($value)) {
|
if ($element === 'statusnet_in_groups' && is_array($value)) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user