return array(
new IPF_Command_Shell,
new IPF_Command_DebugServer,
- new IPF_Command_Routes,
+ new IPF_Command_Routes($c['router']),
new IPF_Command_DB,
new IPF_Command_DBDump,
new IPF_Command_DBRestore,
public $command = 'routes';
public $description = 'Displays all routes';
+ /** @var IPF_Router */
+ private $router;
+
+ function __construct(IPF_Router $router)
+ {
+ $this->router = $router;
+ }
+
public function run($args=null)
{
- $rows = IPF_Project::getInstance()->router->describe();
+ $rows = $this->router->describe();
IPF_Shell::displayTwoColumns($rows);
}
}
-
/** @var Container */
private $container = null;
private $apps = array();
- public $router = null;
public $request = null;
static private $instance = NULL;
$settings->get('app_base')
);
};
- $this->router = $this->container['router'];
}
private function __clone()