def METHOD_NAME(self, binary: bytes, uid: str) -> str:
    type_analysis = self.db.frontend.get_analysis(uid, 'file_type')
    mime = type_analysis.get('mime') if type_analysis is not None else None
    return mime or get_file_type_from_binary(binary)['mime']