def mimes(self):
        """
        Returns extended MimeTypes.
        """
        _mimes = MimeTypes(strict=False)
        _mimes.suffix_map.update({'.tbz2': '.tar.bz2'})
        _mimes.encodings_map.update({'.bz2': 'bzip2'})

        if cfg['CFG_BIBDOCFILE_ADDITIONAL_KNOWN_MIMETYPES']:
            for key, value in iteritems(
                    cfg['CFG_BIBDOCFILE_ADDITIONAL_KNOWN_MIMETYPES']):
                _mimes.add_type(key, value)
                del key, value

        return _mimes
def mimes ( self ) : _mimes = MimeTypes ( strict = False ) _mimes . suffix_map . update ( { '.tbz2' : '.tar.bz2' } ) _mimes . encodings_map . update ( { '.bz2' : 'bzip2' } ) if cfg [ 'CFG_BIBDOCFILE_ADDITIONAL_KNOWN_MIMETYPES' ] : for key , value in iteritems ( cfg [ 'CFG_BIBDOCFILE_ADDITIONAL_KNOWN_MIMETYPES' ] ) : _mimes . add_type ( key , value ) del key , value return _mimes
Returns extended MimeTypes.