protected function getPath($path, $theme = true)
    {
        if ($theme) {
            $themes = SSViewer::get_themes();
            if (is_array($themes)) {
                $themePath = $themes[0];
            } else {
                $themePath = 'simple';
            }
            $path = '/themes/' . $themePath . "/$path";
        }

        return BASE_PATH . $path;
    }