@library.global_function
def get_webfont_attributes(request):
 if (not request):
  return ''
 assume_loaded = 'true'
 if (request.META.get('HTTP_PRAGMA') == 'no-cache'):
  assume_loaded = 'false'
 elif (request.META.get('HTTP_CACHE_CONTROL') == 'no-cache'):
  assume_loaded = 'false'
 elif (request.COOKIES.get('ffo', 'false') == 'true'):
  assume_loaded = 'true'
 else:
  assume_loaded = 'false'
 font_names = ['opensanslight', 'opensans']
 font_attributes = ''
 for font_name in font_names:
  font_attributes += ((((' data-ffo-' + font_name) + '=') + assume_loaded) + '')
 return font_attributes

@ library . global_function def get_webfont_attributes ( request ) : if ( not request ) : return '' assume_loaded = 'true' if ( request . META . get ( 'HTTP_PRAGMA' ) == 'no-cache' ) : assume_loaded = 'false' elif ( request . META . get ( 'HTTP_CACHE_CONTROL' ) == 'no-cache' ) : assume_loaded = 'false' elif ( request . COOKIES . get ( 'ffo' , 'false' ) == 'true' ) : assume_loaded = 'true' else : assume_loaded = 'false' font_names = [ 'opensanslight' , 'opensans' ] font_attributes = '' for font_name in font_names : font_attributes += ( ( ( ( ' data-ffo-' + font_name ) + '=' ) + assume_loaded ) + '' ) return font_attributes
return data attributes based on assumptions about if user has them cached .