def get_current_theme_name(override=None):
 if (override and ((override in themes) or (override == '__common__'))):
  return override
 theme_name = request.args.get('theme', request.preferences.get_value('theme'))
 if (theme_name not in themes):
  theme_name = default_theme
 return theme_name

def get_current_theme_name ( override = None ) : if ( override and ( ( override in themes ) or ( override == '__common__' ) ) ) : return override theme_name = request . args . get ( 'theme' , request . preferences . get_value ( 'theme' ) ) if ( theme_name not in themes ) : theme_name = default_theme return theme_name
returns theme name .