def METHOD_NAME(endpoint, **values):
    """
    Generate the URLs.
    This method will generate the URLs
    """
    if endpoint.endswith('static'):
        themename = values.get('theme', None) or \
            app.config.get('DEFAULT_THEME', None)
        if themename:
            theme_file = "{}/{}".format(themename,
                                        values.get('filename', ''))
            if path.isfile(path.join(app.static_folder, theme_file)):
                values['filename'] = theme_file
    return url_for(endpoint, **values)