File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -35,8 +35,8 @@ class FileLinkFormatter
35
35
];
36
36
37
37
private array |false $ fileLinkFormat ;
38
- private ?RequestStack $ requestStack ;
39
- private ?string $ baseDir ;
38
+ private ?RequestStack $ requestStack = null ;
39
+ private ?string $ baseDir = null ;
40
40
private \Closure |string |null $ urlFormat ;
41
41
42
42
/**
Original file line number Diff line number Diff line change @@ -25,6 +25,13 @@ public function testWhenNoFileLinkFormatAndNoRequest()
25
25
$ this ->assertFalse ($ sut ->format ('/kernel/root/src/my/very/best/file.php ' , 3 ));
26
26
}
27
27
28
+ public function testAfterUnserialize ()
29
+ {
30
+ $ sut = unserialize (serialize (new FileLinkFormatter ()));
31
+
32
+ $ this ->assertFalse ($ sut ->format ('/kernel/root/src/my/very/best/file.php ' , 3 ));
33
+ }
34
+
28
35
public function testWhenFileLinkFormatAndNoRequest ()
29
36
{
30
37
$ file = __DIR__ .\DIRECTORY_SEPARATOR .'file.php ' ;
You can’t perform that action at this time.
0 commit comments