X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Fapiaccountupdatedeliverydevice.php;h=684906fe9019eb75604c733a3e16ff7e4d842218;hb=8957d2bdea569594593c55b7d84f05e2998c0633;hp=5b7176bbbecb723839f4c0cf7e76d5a0d65b4065;hpb=4e4ba24c007fee94662018e7135f2db1e7c847b3;p=quix0rs-gnu-social.git diff --git a/actions/apiaccountupdatedeliverydevice.php b/actions/apiaccountupdatedeliverydevice.php index 5b7176bbbe..684906fe90 100644 --- a/actions/apiaccountupdatedeliverydevice.php +++ b/actions/apiaccountupdatedeliverydevice.php @@ -97,6 +97,8 @@ class ApiAccountUpdateDeliveryDeviceAction extends ApiAuthAction return; } + // Note: Twitter no longer supports IM + if (!in_array(strtolower($this->device), array('sms', 'im', 'none'))) { $this->clientError( _( @@ -135,6 +137,12 @@ class ApiAccountUpdateDeliveryDeviceAction extends ApiAuthAction $twitter_user = $this->twitterUserArray($profile, true); + // Note: this Twitter API method is retarded because it doesn't give + // any success/failure information. Twitter's docs claim that the + // notification field will change to reflect notification choice, + // but that's not true; notification> is used to indicate + // whether the auth user is following the user in question. + if ($this->format == 'xml') { $this->initDocument('xml'); $this->showTwitterXmlUser($twitter_user);