Moved file_get_type() logic to the FileEntity::getFileType(). Override Entity::bundle() to get the current file bundle.