mirror of
https://github.com/PrivateBin/PrivateBin.git
synced 2026-04-18 21:48:24 -04:00
pass by reference, closes #858
This commit is contained in:
+2
-2
@@ -29,7 +29,7 @@ class Json
|
||||
* @throws Exception
|
||||
* @return string
|
||||
*/
|
||||
public static function encode($input)
|
||||
public static function encode(&$input)
|
||||
{
|
||||
$jsonString = json_encode($input);
|
||||
self::_detectError();
|
||||
@@ -45,7 +45,7 @@ class Json
|
||||
* @throws Exception
|
||||
* @return mixed
|
||||
*/
|
||||
public static function decode($input)
|
||||
public static function decode(&$input)
|
||||
{
|
||||
$output = json_decode($input, true);
|
||||
self::_detectError();
|
||||
|
||||
Reference in New Issue
Block a user