def _best_mime():
 supported = []
 renders = {}
 for mime in _MIME_TYPES:
  if app.config.get(mime['tag'], True):
   for mime_type in mime['mime']:
    supported.append(mime_type)
    renders[mime_type] = mime['renderer']
 if (len(supported) == 0):
  abort(500, description=debug_error_message('Configuration error: no supported mime types'))
 best_match = (request.accept_mimetypes.best_match(supported) or supported[0])
 return (best_match, renders[best_match])

def _best_mime ( ) : supported = [ ] renders = { } for mime in _MIME_TYPES : if app . config . get ( mime [ 'tag' ] , True ) : for mime_type in mime [ 'mime' ] : supported . append ( mime_type ) renders [ mime_type ] = mime [ 'renderer' ] if ( len ( supported ) == 0 ) : abort ( 500 , description = debug_error_message ( 'Configuration error: no supported mime types' ) ) best_match = ( request . accept_mimetypes . best_match ( supported ) or supported [ 0 ] ) return ( best_match , renders [ best_match ] )
returns the best match between the requested mime type and the ones supported by eve .