aboutsummaryrefslogtreecommitdiff
path: root/lib/lib_rss.php
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2019-09-18 17:18:36 +0200
committerGravatar GitHub <noreply@github.com> 2019-09-18 17:18:36 +0200
commite761202f8a4c30cd0cb22190728cf0a61a3271bb (patch)
tree93176f35bda9cac8786a4032264478293ffa07f6 /lib/lib_rss.php
parenta8bbcef551e5b93ac1c349cb3d4a754a5c67126c (diff)
Remove JSON.php fallback (#2528)
After moving to PHP 5.6+ https://github.com/FreshRSS/FreshRSS/pull/2527 it should not be necessary to have the JSON.php fallback anymore, which was mainly there due to an obscure licensing issue 6 years ago in Debian https://wiki.debian.org/qa.debian.org/jsonevil , which broke Ubuntu 13.10 https://github.com/FreshRSS/FreshRSS/issues/306
Diffstat (limited to 'lib/lib_rss.php')
-rw-r--r--lib/lib_rss.php16
1 files changed, 0 insertions, 16 deletions
diff --git a/lib/lib_rss.php b/lib/lib_rss.php
index b810e1296..1bba60c36 100644
--- a/lib/lib_rss.php
+++ b/lib/lib_rss.php
@@ -3,22 +3,6 @@ if (version_compare(PHP_VERSION, '5.6.0', '<')) {
die('FreshRSS error: FreshRSS requires PHP 5.6.0+!');
}
-if (!function_exists('json_decode')) { //PHP bug #63520 < PHP 7
- require_once(__DIR__ . '/JSON.php');
- function json_decode($var, $assoc = false) {
- $JSON = new Services_JSON($assoc ? SERVICES_JSON_LOOSE_TYPE : 0);
- return $JSON->decode($var);
- }
-}
-
-if (!function_exists('json_encode')) {
- require_once(__DIR__ . '/JSON.php');
- function json_encode($var) {
- $JSON = new Services_JSON();
- return $JSON->encodeUnsafe($var);
- }
-}
-
if (!function_exists('mb_strcut')) {
function mb_strcut($str, $start, $length = null, $encoding = 'UTF-8') {
return substr($str, $start, $length);