Skip to content

Commit de1921e

Browse files
committed
feat: add return type hints
This patch adds a return type hint to `ContainerInterface::has()`, per the already documented specification, in preparation for a v3 release. No other methods were eligible, as they specified `mixed`. See https://www.php-fig.org/blog/2019/10/upgrading-psr-interfaces/ Signed-off-by: Matthew Weier O'Phinney <[email protected]>
1 parent 6c2bc7f commit de1921e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
},
2222
"extra": {
2323
"branch-alias": {
24-
"dev-master": "2.0.x-dev"
24+
"dev-master": "3.0.x-dev"
2525
}
2626
}
2727
}

src/ContainerInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@ public function get(string $id);
3232
*
3333
* @return bool
3434
*/
35-
public function has(string $id);
35+
public function has(string $id): bool;
3636
}

0 commit comments

Comments
 (0)