Skip to content

Commit

Permalink
fix phpcs
Browse files Browse the repository at this point in the history
  • Loading branch information
Ondřej Ešler committed Jul 10, 2020
1 parent 99361b9 commit f4c561b
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/ServiceContainer.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,17 +70,16 @@ public function factory(string $id): callable
/**
* Finds an entry of the container by its identifier and returns it.
*
* @template T
* @param class-string<T> $id Identifier of the entry to look for.
*
* @return mixed Entry.
* @return T
*
* @throws NotFoundExceptionInterface No entry was found for **this** identifier.
* @throws ContainerExceptionInterface Error while retrieving the entry.
*
* @return T
* @template T
*/
public function get($id) // phpcs:ignore SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint
public function get($id) // phpcs:ignore SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint,SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingNativeTypeHint,Generic.Files.LineLength.TooLong
{
if (isset($this->instances[$id])) {
return $this->instances[$id]; // try load a singleton if saved
Expand Down Expand Up @@ -137,12 +136,13 @@ public function singleton(string $id)
/**
* Makes a new instance of a service. Dependencies are resolved from the container.
*
* @template T
* @param class-string<T> $id ID of entry we want to create new instance of
*
* @return T
*
* @template T
*/
public function make(string $id)
public function make(string $id) // phpcs:ignore SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingNativeTypeHint,Generic.Files.LineLength.TooLong
{
$instance = $this->factory($id)($this);

Expand Down

0 comments on commit f4c561b

Please sign in to comment.