This commit is contained in:
Simon Vieille 2015-05-05 22:06:02 +02:00
parent 843cf43b54
commit 44d90ab942
6 changed files with 4 additions and 7 deletions

View file

@ -5,4 +5,3 @@ use Gist\Application;
$app = Application::getInstance(); $app = Application::getInstance();
$app['root_path'] = __DIR__ . '/../..'; $app['root_path'] = __DIR__ . '/../..';

View file

@ -10,4 +10,3 @@ $app->error(function (Exception $e, $code) use ($app) {
) )
); );
}); });

View file

@ -10,6 +10,6 @@ $app['routing.loader'] = function ($app) {
$app['routes'] = $app->extend('routes', function ($routes, $app) { $app['routes'] = $app->extend('routes', function ($routes, $app) {
$routes->addCollection($app['routing.loader']->load($app['routing.file'])); $routes->addCollection($app['routing.loader']->load($app['routing.file']));
return $routes; return $routes;
}); });

View file

@ -11,4 +11,3 @@ $app->extend('twig', function ($twig, $app) {
return $twig; return $twig;
}); });

View file

@ -3,7 +3,7 @@
use GitWrapper\GitWrapper; use GitWrapper\GitWrapper;
$app['git'] = function ($app) { $app['git'] = function ($app) {
echo "ok"; echo "ok";
return new GitWrapper(); return new GitWrapper();
}; };

View file

@ -15,7 +15,7 @@ class HomeController
public function indexAction(Request $request, Application $app) public function indexAction(Request $request, Application $app)
{ {
$form = new CreateGistForm($app['form.factory'], $app['translator']); $form = new CreateGistForm($app['form.factory'], $app['translator']);
$form = $form->build(); $form = $form->build();
return $app['twig']->render( return $app['twig']->render(
'Home/index.html.twig', 'Home/index.html.twig',