BSF_Update_Manager::plugin_information( array $brainstrom_products = array() )

Install Pluigns Filter


Description

Add brainstorm bundle products in plugin installer list though filter.


Parameters

$brainstrom_products

(array) (Optional) Brainstorm Products.

Default value: array()


Return

(array) Brainstorm Products merged with Brainstorm Bundle Products.


Source

File: admin/bsf-core/class-bsf-update-manager.php

		public function plugin_information( $brainstrom_products = array() ) {

			$main_products = (array) get_option( 'brainstrom_bundled_products', array() );

			foreach ( $main_products as $single_product_key => $single_product ) {
				foreach ( $single_product as $bundle_product_key => $bundle_product ) {

					if ( is_object( $bundle_product ) ) {
						$type = $bundle_product->type;
						$slug = $bundle_product->slug;
					} else {
						$type = $bundle_product['type'];
						$slug = $bundle_product['slug'];
					}

					// Add bundled plugin in installer list.
					if ( 'plugin' === $type ) {
						$brainstrom_products['plugins'][ $slug ] = (array) $bundle_product;
					}
				}
			}

			return $brainstrom_products;
		}

Changelog

Changelog
Version Description
1.0.0 Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.