Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"description": "Dependency injection service container",
"type": "library",
"license": "MIT",
"version": "1.0",
"version": "1.1",
"autoload": {
"psr-4": {
"Micro\\Component\\DependencyInjection\\": "src/"
Expand Down
11 changes: 6 additions & 5 deletions src/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@

namespace Micro\Component\DependencyInjection;


use Micro\Component\DependencyInjection\Autowire\AutowireHelperFactory;
use Micro\Component\DependencyInjection\Autowire\AutowireHelperFactoryInterface;
use Micro\Component\DependencyInjection\Exception\ServiceNotRegisteredException;
use Micro\Component\DependencyInjection\Exception\ServiceRegistrationException;
use \Closure;
Expand Down Expand Up @@ -35,9 +32,13 @@ public function __construct(
}

/**
* {@inheritDoc}
* @template T
*
* @param class-string<T> $id
*
* @return T
*/
public function get(string $id)
public function get(string $id): object
{
return $this->lookup($id);
}
Expand Down