X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=inline;f=lib%2Ftwitterapi.php;h=096dee2696060d1f25b7e32e2697a4065cecc233;hb=b9f0ea6f0e16f2314a2bdd56365205e7a3c31aa1;hp=8b4c24cabc77f8152b2e75c3cacc0275c48e0c7d;hpb=35d17146213228445b0f30548aca01c9e1a71154;p=quix0rs-gnu-social.git diff --git a/lib/twitterapi.php b/lib/twitterapi.php index 8b4c24cabc..096dee2696 100644 --- a/lib/twitterapi.php +++ b/lib/twitterapi.php @@ -150,28 +150,6 @@ class TwitterapiAction extends Action { function show_twitter_json_users($twitter_users) { print(json_encode($twitter_users)); } - - function show($args, $apidata) { - parent::handle($args); - - $id = $apidata['api_arg']; - $notice = Notice::staticGet($id); - - if ($notice) { - if ($apidata['content-type'] == 'xml') { - $this->show_single_xml_status($notice); - } elseif ($apidata['content-type'] == 'json') { - $this->show_single_json_status($notice); - } - } else { - - // XXX: This is all that Twitter does. It doesn't show an XML or JSON error msg. - // Should we call client_error() to be more consistent? - header('HTTP/1.1 404 Not Found'); - } - - exit(); - } function show_single_xml_status($notice) { $this->init_document('xml'); @@ -245,7 +223,7 @@ class TwitterapiAction extends Action { $this->init_twitter_atom(); break; default: - $this->client_error(_('Unsupported type')); + $this->client_error(_('Not a supported data format.')); break; } @@ -266,7 +244,7 @@ class TwitterapiAction extends Action { $this->end_twitter_rss(); break; default: - $this->client_error(_('Unsupported type')); + $this->client_error(_('Not a supported data format.')); break; } return; @@ -351,7 +329,7 @@ class TwitterapiAction extends Action { $this->show_twitter_json_users($profile_array); break; default: - $this->client_error(_('not a supported data format')); + $this->client_error(_('Not a supported data format.')); return; } return;