src/Injector.php
public function resolve($contract, array $args = [])
    {
        // return contract if contract is signature of function
        if (is_callable($contract)) {
            return $contract;
        } elseif (is_string($contract)) {
            return $this->resolveClass($contract, $args);
        } elseif (is_array($contract) && isset($contract[0])) {
            $realContract = $contract[0];
            $realArgs = (new Options(isset($contract[1]) ? $contract[1] : []))
                ->merge($args)
                ->toArray();

            return $this->resolveClass($realContract, $realArgs);
        } else {
            return $contract;
        }
    }
public function resolve($contract, array $args = [])
    {
        // return contract if contract is signature of function
        if (is_callable($contract)) {
            return $contract;
        } elseif (is_string($contract)) {
            return $this->resolveClass($contract, $args);
        } elseif (is_array($contract) && isset($contract[0])) {
            $realContract = $contract[0];
            $realArgs = (new Options(isset($contract[1]) ? $contract[1] : []))
                ->merge($args)
                ->toArray();

            return $this->resolveClass($realContract, $realArgs);
        } else {
            return $contract;
        }
    }
Resolve contract

@param mixed $contract
@param array $args
@return mixed