Skip to content

Commit

Permalink
Renamed method Container::_provide() on Container::getInternal().
Browse files Browse the repository at this point in the history
  • Loading branch information
romeOz committed Jan 27, 2015
1 parent 545423c commit edda4b7
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public static function load(/*$args...*/$config, $throwException = true)
}
return static::newInstance($class, $config ? [$config] : $config, $args);
}
$data = static::_provide($class);
$data = static::getInternal($class);
// Lazy (single instance)
if (static::isSingleton($class)) {
$instance = static::getSingleton($data, $config, $args);
Expand All @@ -111,7 +111,7 @@ public static function load(/*$args...*/$config, $throwException = true)
public static function get($name)
{
$name = ltrim($name, '\\');
if (!$data = self::_provide($name)) {
if (!$data = self::getInternal($name)) {
return null;
}

Expand Down Expand Up @@ -254,7 +254,6 @@ protected static function getSingleton(array $data, array $config = [], array $a
return static::$instances[$data['alias']];
}
if ($instance = self::getInstance($data, $config, $args)) {
//static::_callPermanentInit($instance, $data);
return static::$instances[$data['alias']] = $instance;
}

Expand Down Expand Up @@ -385,7 +384,7 @@ protected static function calculateConfig($config)
return [$class, $config];
}

protected static function _provide($name)
protected static function getInternal($name)
{
if (!empty(static::$classNames[$name])) {
return static::$classNames[$name];
Expand Down

0 comments on commit edda4b7

Please sign in to comment.