def get_first_gallery(entry):
    """Returns the first gallery plugin of a blog Entry."""
    for plugin in entry.content.get_plugins():
        if plugin.get_plugin_name().title() == 'Folder':
            return plugin
    return False