protected function doBuild($user, $isApi = false)
    {
        $this->register($user, $isApi);

        $this->container->setAlias(
            $this->alias($user, $isApi),
            $this->definition($user, $isApi)
        );

        return $this->container;
    }