classes/Errors/HandlerResolver.php
public function resolve($handler)
	{
		if (!is_string($handler)) {
			return $handler;
		}

		$handler = $this->container->resolve($handler);

		if (!is_callable($handler) && !$handler instanceof ErrorHandlerInterface) {
			$type = is_object($handler) ? get_class($handler) : gettype($handler);
			throw new \UnexpectedValueException("Resolved error handler is not a valid handler - must be callable or an instance of Autarky\Errors\ErrorHandlerInterface, $type given");
		}

		return $handler;
	}
public function resolve($handler)
	{
		if (!is_string($handler)) {
			return $handler;
		}

		$handler = $this->container->resolve($handler);

		if (!is_callable($handler) && !$handler instanceof ErrorHandlerInterface) {
			$type = is_object($handler) ? get_class($handler) : gettype($handler);
			throw new \UnexpectedValueException("Resolved error handler is not a valid handler - must be callable or an instance of Autarky\Errors\ErrorHandlerInterface, $type given");
		}

		return $handler;
	}
Resolve a handler.

@param  mixed $handler

@return ErrorHandlerInterface|callable