more refactoring for dependency injection.
This commit is contained in:
@@ -26,6 +26,19 @@ abstract class Controller {
|
||||
|
||||
/**
|
||||
* Dynamically resolve items from the application IoC container.
|
||||
*
|
||||
* First, "laravel." will be prefixed to the requested item to see if there is
|
||||
* a matching Laravel core class in the IoC container. If there is not, we will
|
||||
* check for the item in the container using the name as-is.
|
||||
*
|
||||
* <code>
|
||||
* // Resolve the "laravel.input" instance from the IoC container
|
||||
* $input = $this->input;
|
||||
*
|
||||
* // Resolve the "mailer" instance from the IoC container
|
||||
* $mongo = $this->mailer;
|
||||
* </code>
|
||||
*
|
||||
*/
|
||||
public function __get($key)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user