public function getSidebar($sidebar_name)
    {
        global $wp_registered_sidebars;

        $sidebar_id = null;

        foreach ($wp_registered_sidebars as $registered_sidebar_id => $registered_sidebar) {
            if ($sidebar_name === $registered_sidebar['name']) {
                $sidebar_id = $registered_sidebar_id;
                break;
            }
        }

        if ($sidebar_id === null) {
            throw new UnexpectedValueException(sprintf('[W614] Sidebar "%s" does not exist', $sidebar_name));
        }

        return $sidebar_id;
    }