def get_themes(themes_dir=None):
    """
    get a list of all themes known to the system.

    Args:
        themes_dir (str): (Optional) Path to themes base directory
    Returns:
        list of themes known to the system.
    """
    if not is_comprehensive_theming_enabled():
        return []
    if themes_dir is None:
        themes_dir = get_theme_base_dirs_unchecked()
    return get_themes_unchecked(themes_dir, settings.PROJECT_ROOT)
Beispiel #2
0
def get_themes(themes_dir=None):
    """
    get a list of all themes known to the system.

    Args:
        themes_dir (str): (Optional) Path to themes base directory
    Returns:
        list of themes known to the system.
    """
    if not is_comprehensive_theming_enabled():
        return []
    if themes_dir is None:
        themes_dir = get_theme_base_dirs_unchecked()
    return get_themes_unchecked(themes_dir, settings.PROJECT_ROOT)