diff --git a/plugins/httprpc/action.php b/plugins/httprpc/action.php index e5d957698..b4208958d 100644 --- a/plugins/httprpc/action.php +++ b/plugins/httprpc/action.php @@ -496,4 +496,4 @@ function makeSimpleCall($cmds,$hash) CachedEcho::send( (isset($req) && $req->fault) ? "Warning: XMLRPC call is failed." : "Link to XMLRPC failed. Maybe, rTorrent is down?","text/html"); } else - CachedEcho::send(JSON::safeEncode($result),"application/json"); + CachedEcho::send(json_encode($result, JSON_THROW_ON_ERROR|JSON_INVALID_UTF8_SUBSTITUTE), "application/json");