function( sites, pluginSlug ) {
		let plugin,
			plugins = this.getPlugins( sites ),
			pluginSites;
		if ( ! plugins ) {
			return;
		}

		plugin = find( plugins, _filters.isEqual.bind( this, pluginSlug ) );
		if ( ! plugin ) {
			return null;
		}

		pluginSites = plugin.sites
			.filter( site => site.visible )
			.map( site => {
				// clone the site object before adding a new property. Don't modify the return value of getSite
				const pluginSite = clone( getSite( reduxGetState(), site.ID ) );
				pluginSite.plugin = site.plugin;
				return pluginSite;
			} );

		return pluginSites.sort( function( first, second ) {
			return first.title.toLowerCase() > second.title.toLowerCase() ? 1 : -1;
		} );
	}
function( sites, pluginSlug ) {
		let plugin,
			plugins = this.getPlugins( sites ),
			pluginSites;
		if ( ! plugins ) {
			return;
		}

		plugin = find( plugins, _filters.isEqual.bind( this, pluginSlug ) );
		if ( ! plugin ) {
			return null;
		}

		pluginSites = plugin.sites
			.filter( site => site.visible )
			.map( site => {
				
				const pluginSite = clone( getSite( reduxGetState(), site.ID ) );
				pluginSite.plugin = site.plugin;
				return pluginSite;
			} );

		return pluginSites.sort( function( first, second ) {
			return first.title.toLowerCase() > second.title.toLowerCase() ? 1 : -1;
		} );
	}
function ( sites , pluginSlug ) { let plugin , plugins = this . getPlugins ( sites ) , pluginSites ; if ( ! plugins ) { return ; } plugin = find ( plugins , _filters . isEqual . bind ( this , pluginSlug ) ) ; if ( ! plugin ) { return null ; } pluginSites = plugin . sites . filter ( site => site . visible ) . map ( site => { // clone the site object before adding a new property. Don't modify the return value of getSite const pluginSite = clone ( getSite ( reduxGetState ( ) , site . ID ) ) ; pluginSite . plugin = site . plugin ; return pluginSite ; } ) ; return pluginSites . sort ( function ( first , second ) { return first . title . toLowerCase ( ) > second . title . toLowerCase ( ) ? 1 : - 1 ; } ) ; }
Array of sites with a particular plugin.
Array of sites with a particular plugin .