Skip to content

Commit 153799c

Browse files
authored
Merge pull request #35 from bigcommerce/fix/psr11-string-type-hints
fix: add string type hints to has()/get() for psr/container 2.x compat on PHP 8.3
2 parents 7cf1fc2 + ecfb7b0 commit 153799c

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/ProphecyMockingContainer.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public function checkPredictions()
4343
* @param string $id
4444
* @return mixed
4545
*/
46-
public function get($id)
46+
public function get(string $id)
4747
{
4848
return $this->createOrGetMock($id)->reveal();
4949
}
@@ -53,7 +53,7 @@ public function get($id)
5353
* @param string $id
5454
* @return bool
5555
*/
56-
public function has($id): bool
56+
public function has(string $id): bool
5757
{
5858
return (class_exists($id) || interface_exists($id));
5959
}

0 commit comments

Comments
 (0)