diff --git a/src/bootstrap/main.php b/src/bootstrap/main.php index dae1aae..e115bc4 100644 --- a/src/bootstrap/main.php +++ b/src/bootstrap/main.php @@ -163,6 +163,16 @@ final class registry { final class di { protected $services = []; + + // alias to register + public function set(...$args): void { + $this->register(...$args); + } + + // alias to get_service + public function get(...$args) { + return $this->get_service(...$args); + } public function register(string $service_name, callable $callable): void { $this->services[$service_name] = $callable;