(fname)
return mimetype
Return mimetype for a known text filename
Return mimetype for a known text filename
Return mimetype for a known text filename
def guess_mimetype(fname):
    "Return mimetype for a known text filename"

    mimetype, encoding = guess_type(fname)

    ext = os.path.splitext(fname)[1].lower()

    # Known text extensions ( .fasta, .fastq, etc.. )
    if ext in KNOWN_TEXT_EXTENSIONS:
        mimetype = 'text/plain'

    return mimetype
def guess_mimetype ( fname ) : mimetype , encoding = guess_type ( fname ) ext = os . path . splitext ( fname ) [ 1 ] . lower ( ) # Known text extensions ( .fasta, .fastq, etc.. ) if ext in KNOWN_TEXT_EXTENSIONS : mimetype = 'text/plain' return mimetype