public function load($name, $group = null)
	{
		if ($group === true)
		{
			$group = pathinfo($name, PATHINFO_FILENAME);
		}

		if ($group and $cached = $this->get($group))
		{
			return $cached;
		}

		$name = $this->ensureDefaultFormat($name);
		$paths = $this->finder->findAllFiles($name);

		if (empty($paths))
		{
			return false;
		}

		$config = array();

		foreach ($paths as $path)
		{
			$extension = pathinfo($path, PATHINFO_EXTENSION);
			$handler = $this->getHandler($extension);
			$config = Arr::merge($config, $handler->load($path));
		}

		if ($group)
		{
			$this->set($group, $config);
		}
		elseif ($group === null)
		{
			$this->merge($config);
		}

		return $config;
	}
public function load($name, $group = null)
	{
		if ($group === true)
		{
			$group = pathinfo($name, PATHINFO_FILENAME);
		}

		if ($group and $cached = $this->get($group))
		{
			return $cached;
		}

		$name = $this->ensureDefaultFormat($name);
		$paths = $this->finder->findAllFiles($name);

		if (empty($paths))
		{
			return false;
		}

		$config = array();

		foreach ($paths as $path)
		{
			$extension = pathinfo($path, PATHINFO_EXTENSION);
			$handler = $this->getHandler($extension);
			$config = Arr::merge($config, $handler->load($path));
		}

		if ($group)
		{
			$this->set($group, $config);
		}
		elseif ($group === null)
		{
			$this->merge($config);
		}

		return $config;
	}
public function load ( $ name , $ group = null ) { if ( $ group === true ) { $ group = pathinfo ( $ name , PATHINFO_FILENAME ) ; } if ( $ group and $ cached = $ this -> get ( $ group ) ) { return $ cached ; } $ name = $ this -> ensureDefaultFormat ( $ name ) ; $ paths = $ this -> finder -> findAllFiles ( $ name ) ; if ( empty ( $ paths ) ) { return false ; } $ config = array ( ) ; foreach ( $ paths as $ path ) { $ extension = pathinfo ( $ path , PATHINFO_EXTENSION ) ; $ handler = $ this -> getHandler ( $ extension ) ; $ config = Arr :: merge ( $ config , $ handler -> load ( $ path ) ) ; } if ( $ group ) { $ this -> set ( $ group , $ config ) ; } elseif ( $ group === null ) { $ this -> merge ( $ config ) ; } return $ config ; }
Loads a config file

@param string              $name
@param null|string|boolean $group

@return array|null
Loads a config file