From d9c895ce4f53b180fc11c3b5a172c4cf787b1279 Mon Sep 17 00:00:00 2001 From: Florian Pritz Date: Tue, 3 Feb 2015 11:18:28 +0100 Subject: Remove unstable json api Signed-off-by: Florian Pritz --- application/controllers/file.php | 20 -------------------- application/controllers/user.php | 9 --------- 2 files changed, 29 deletions(-) (limited to 'application/controllers') diff --git a/application/controllers/file.php b/application/controllers/file.php index e35978a1e..63f6a71b5 100644 --- a/application/controllers/file.php +++ b/application/controllers/file.php @@ -9,13 +9,6 @@ class File extends MY_Controller { - protected $json_enabled_functions = array( - "upload_history", - "do_upload", - "do_delete", - "do_multipaste", - ); - function __construct() { parent::__construct(); @@ -470,10 +463,6 @@ class File extends MY_Controller { } } - if (static_storage("response_type") == "json") { - return send_json_reply($this->data["urls"]); - } - if (is_cli_client()) { $redirect = false; } @@ -740,15 +729,6 @@ class File extends MY_Controller { ); } - if (static_storage("response_type") == "json") { - return send_json_reply(array( - "errors" => $errors, - "deleted" => $deleted, - "total_count" => $total_count, - "deleted_count" => $deleted_count, - )); - } - $this->data["errors"] = $errors; $this->data["deleted_count"] = $deleted_count; $this->data["total_count"] = $total_count; diff --git a/application/controllers/user.php b/application/controllers/user.php index 62569e1f1..aba2a8ec1 100644 --- a/application/controllers/user.php +++ b/application/controllers/user.php @@ -8,11 +8,6 @@ */ class User extends MY_Controller { - protected $json_enabled_functions = array( - "create_apikey", - "apikeys", - ); - function __construct() { @@ -93,10 +88,6 @@ class User extends MY_Controller { $key = \service\user::create_apikey($userid, $comment, $access_level); - if (static_storage("response_type") == "json") { - return send_json_reply(array("new_key" => $key)); - } - if (is_cli_client()) { echo "$key\n"; } else { -- cgit v1.2.3-24-g4f1b