def METHOD_NAME(cls, definition, meta_item_path):
    if definition is not None:
        return definition.file_type
    else:
        return (
            MetaItemFileType.get_from_suffix(meta_item_path)
            or MetaItemFileType.UNKNOWN
        )