public function end()
    {
        if ($this->getCounter() === 0)
        {
            throw new \RuntimeException("The section {$this->name} already closed.");
        }

        $this->appendContent(ob_get_clean());

        $this->counter--;

        /**
         * @deprecated
        */
        $this->closed = $this->isClosed();
    }