We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 06ec61f commit 609ee69Copy full SHA for 609ee69
rector.php
@@ -47,7 +47,6 @@
47
],
48
ReturnTypeDeclarationRector::class => [
49
__DIR__ . '/src/Controller',
50
- __DIR__ . '/spec/Fixture/NotSupportedContainer.php',
51
52
]);
53
};
spec/Fixture/NotSupportedContainer.php
@@ -7,12 +7,17 @@
7
8
class NotSupportedContainer implements ContainerInterface
9
{
10
- /**
11
- * @return stdClass
12
- */
13
- public function get($id) { return new stdClass(); }
14
15
- * @return bool
16
17
- public function has($id) { return true; }
+ public function get($id): stdClass|array
+ {
+ if (random_int(0, 1) !== 0) {
+ return new stdClass();
+ }
+
+ return [];
18
19
+ public function has($id): bool
20
21
+ return true;
22
23
}
0 commit comments