summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2018-03-19 12:28:23 +0100
committerGitHub <noreply@github.com>2018-03-19 12:28:23 +0100
commit0929e048f83bb8643e630c14d72314ac54e32fde (patch)
tree10fba385b233cfacfcec04e764fbf26e2feb803a /lib
parent05203e3fc0fbdecb70f49573a1068d1c8408445d (diff)
parent68871caf3ce7b59dc977dd198681b42121ca7259 (diff)
downloadnextcloud-server-0929e048f83bb8643e630c14d72314ac54e32fde.tar.gz
nextcloud-server-0929e048f83bb8643e630c14d72314ac54e32fde.zip
Merge pull request #8879 from nextcloud/dep_json
Remove unused deprecated functions from OCP\JSON
Diffstat (limited to 'lib')
-rw-r--r--lib/private/legacy/json.php15
-rw-r--r--lib/public/JSON.php32
2 files changed, 0 insertions, 47 deletions
diff --git a/lib/private/legacy/json.php b/lib/private/legacy/json.php
index 0afa179b3d8..b02e5c879fc 100644
--- a/lib/private/legacy/json.php
+++ b/lib/private/legacy/json.php
@@ -112,21 +112,6 @@ class OC_JSON{
}
/**
- * Check is a given user exists - send json error msg if not
- * @param string $user
- * @deprecated Use a AppFramework JSONResponse instead
- * @suppress PhanDeprecatedFunction
- */
- public static function checkUserExists($user) {
- if (!\OC::$server->getUserManager()->userExists($user)) {
- $l = \OC::$server->getL10N('lib');
- OCP\JSON::error(array('data' => array('message' => $l->t('Unknown user'), 'error' => 'unknown_user' )));
- exit;
- }
- }
-
-
- /**
* Check if the user is a subadmin, send json error msg if not
* @deprecated Use annotation based ACLs from the AppFramework instead
* @suppress PhanDeprecatedFunction
diff --git a/lib/public/JSON.php b/lib/public/JSON.php
index c56c3b645a9..151a590b294 100644
--- a/lib/public/JSON.php
+++ b/lib/public/JSON.php
@@ -42,18 +42,6 @@ namespace OCP;
*/
class JSON {
/**
- * Encode and print $data in JSON format
- * @param array $data The data to use
- * @param bool $setContentType the optional content type
- * @deprecated 8.1.0 Use a AppFramework JSONResponse instead
- *
- * @suppress PhanDeprecatedFunction
- */
- public static function encodedPrint( $data, $setContentType=true ) {
- \OC_JSON::encodedPrint($data, $setContentType);
- }
-
- /**
* Check if the user is logged in, send json error msg if not.
*
* This method checks if a user is logged in. If not, a json error
@@ -136,16 +124,6 @@ class JSON {
}
/**
- * Set Content-Type header to jsonrequest
- * @param string $type The content type header
- * @deprecated 8.1.0 Use a AppFramework JSONResponse instead
- * @suppress PhanDeprecatedFunction
- */
- public static function setContentTypeHeader( $type='application/json' ) {
- \OC_JSON::setContentTypeHeader($type);
- }
-
- /**
* Check if the App is enabled and send JSON error message instead
*
* This method checks if a specific app is enabled. If not, a json error
@@ -196,14 +174,4 @@ class JSON {
public static function encode($data) {
return \OC_JSON::encode($data);
}
-
- /**
- * Check is a given user exists - send json error msg if not
- * @param string $user
- * @deprecated 8.1.0 Use a AppFramework JSONResponse instead
- * @suppress PhanDeprecatedFunction
- */
- public static function checkUserExists($user) {
- \OC_JSON::checkUserExists($user);
- }
}