File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,11 @@ protected function initialize(): array {
5050 $ ext = new \ReflectionExtension ($ name );
5151 try {
5252 $ prettyVersion = $ ext ->getVersion ();
53- $ prettyVersion = $ this ->normalizeVersion ($ prettyVersion );
53+ /** @psalm-suppress TypeDoesNotContainNull
54+ * @psalm-suppress RedundantCondition
55+ * TODO Remove these annotations once psalm fixes the method signature ( https://github.com/vimeo/psalm/pull/8655 )
56+ */
57+ $ prettyVersion = $ this ->normalizeVersion ($ prettyVersion ?? '0 ' );
5458 } catch (\UnexpectedValueException $ e ) {
5559 $ prettyVersion = '0 ' ;
5660 $ prettyVersion = $ this ->normalizeVersion ($ prettyVersion );
@@ -111,6 +115,9 @@ protected function initialize(): array {
111115 continue 2 ;
112116 }
113117
118+ if ($ prettyVersion === null ) {
119+ continue ;
120+ }
114121 try {
115122 $ prettyVersion = $ this ->normalizeVersion ($ prettyVersion );
116123 } catch (\UnexpectedValueException $ e ) {
You can’t perform that action at this time.
0 commit comments