From 4e527a860130837d9b153eebd856b68ab84bc008 Mon Sep 17 00:00:00 2001 From: Guillaume Mazoyer Date: Wed, 13 Aug 2014 00:37:41 +0200 Subject: Tiny change, pass as parameter of the constructor. --- index.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/index.php b/index.php index 0ea98c4..3e192f1 100644 --- a/index.php +++ b/index.php @@ -1,4 +1,5 @@ @@ -27,9 +28,7 @@ final class LookingGlass { private $misc; private $routers; - function __construct() { - global $config; - + function __construct($config) { $this->frontpage = $config['frontpage']; $this->contact = $config['contact']; $this->misc = $config['misc']; @@ -243,7 +242,7 @@ final class LookingGlass { } } -$looking_glass = new LookingGlass(); +$looking_glass = new LookingGlass($config); $looking_glass->render(); // End of index.php -- cgit v1.2.3