File tree Expand file tree Collapse file tree 2 files changed +1
-10
lines changed Expand file tree Collapse file tree 2 files changed +1
-10
lines changed Original file line number Diff line number Diff line change @@ -355,7 +355,7 @@ public static function jsonDecode(string $input)
355
355
public static function jsonEncode (array $ input ): string
356
356
{
357
357
if (PHP_VERSION_ID >= 50400 ) {
358
- $ json = \json_encode ($ input , \JSON_UNESCAPED_SLASHES |\ JSON_FORCE_OBJECT );
358
+ $ json = \json_encode ($ input , \JSON_UNESCAPED_SLASHES );
359
359
} else {
360
360
// PHP 5.3 only
361
361
$ json = \json_encode ($ input );
Original file line number Diff line number Diff line change @@ -321,15 +321,6 @@ public function testRSEncodeDecodeWithPassphrase()
321
321
$ this ->assertEquals ($ decoded , $ expected );
322
322
}
323
323
324
- public function testDecodesEmptyArrayAsObject ()
325
- {
326
- $ key = 'yma6Hq4XQegCVND8ef23OYgxSrC3IKqk ' ;
327
- $ payload = [];
328
- $ jwt = JWT ::encode ($ payload , $ key , 'HS256 ' );
329
- $ decoded = JWT ::decode ($ jwt , new Key ($ key , 'HS256 ' ));
330
- $ this ->assertEquals ((object ) $ payload , $ decoded );
331
- }
332
-
333
324
/**
334
325
* @runInSeparateProcess
335
326
* @dataProvider provideEncodeDecode
You can’t perform that action at this time.
0 commit comments