Browse Source

added bundle option

Taylor Otwell 13 years ago
parent
commit
38da9f47b9
1 changed files with 14 additions and 0 deletions
  1. 14 0
      laravel/bundle.php

+ 14 - 0
laravel/bundle.php

@@ -408,6 +408,20 @@ class Bundle {
 		return (object) array_get(static::$bundles, $bundle);
 	}
 
+	/**
+	 * Get an option for a given bundle.
+	 *
+	 * @param  string  $bundle
+	 * @param  string  $option
+	 * @return mixed
+	 */
+	public static function option($bundle, $option)
+	{
+		$bundle = static::get($bundle);
+
+		if ( ! is_null($bundle)) return array_get($bundle, $option);
+	}
+
 	/**
 	 * Get all of the installed bundles for the application.
 	 *