Passed
Push — Admin-section ( 9cd175...8dfc72 )
by Stone
01:50
created
Core/Controller.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
 
61 61
         //We load all our module objects into our object
62 62
         foreach ($this->loadModules as $loadModule) {
63
-            $loadModuleObj = 'Core\\Modules\\' . $loadModule;
63
+            $loadModuleObj = 'Core\\Modules\\'.$loadModule;
64 64
 
65 65
             $loadModuleName = lcfirst($loadModule);
66 66
             $loadedModule = new $loadModuleObj($this->container);
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 
72 72
             //we are not allowed to create public modules, they must be a placeholder ready
73 73
             if (!property_exists($this, $loadModuleName)) {
74
-                throw new \ErrorException('class var ' . $loadModuleName . ' not present');
74
+                throw new \ErrorException('class var '.$loadModuleName.' not present');
75 75
             }
76 76
             $this->$loadModuleName = $loadedModule;
77 77
         }
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
     public function getView($template)
103 103
     {
104 104
         $twig = $this->container->getTemplate();
105
-        return $twig->render($template . '.twig', $this->data);
105
+        return $twig->render($template.'.twig', $this->data);
106 106
     }
107 107
 
108 108
     /**
@@ -119,22 +119,22 @@  discard block
 block discarded – undo
119 119
         if ($this->alertBox->alertsPending()) {
120 120
             $this->data['alert_messages'] = $this->alertBox->getAlerts();
121 121
         }
122
-        if(Config::DEV_ENVIRONMENT){
122
+        if (Config::DEV_ENVIRONMENT) {
123 123
             $this->devHelper();
124 124
         }
125 125
         $twig = $this->container->getTemplate();
126
-        $twig->display($template . '.twig', $this->data);
126
+        $twig->display($template.'.twig', $this->data);
127 127
     }
128 128
 
129
-    protected function devHelper($var = ''){
130
-        if(!isset($this->data['dev_info'])){
129
+    protected function devHelper($var = '') {
130
+        if (!isset($this->data['dev_info'])) {
131 131
             $this->data['dev'] = true;
132
-            $classMethods =[];
133
-            if($var != ''){
132
+            $classMethods = [];
133
+            if ($var != '') {
134 134
                 $classMethods['passed_var'] = $var;
135 135
             }
136
-            $classMethods['class_object_methods']=get_class_methods(get_class($this));
137
-            $classMethods['class_object_vars']=get_object_vars($this);
136
+            $classMethods['class_object_methods'] = get_class_methods(get_class($this));
137
+            $classMethods['class_object_vars'] = get_object_vars($this);
138 138
             $classMethods['session_vars'] = $_SESSION;
139 139
 
140 140
             $this->data['dev_info'] = $classMethods;
Please login to merge, or discard this patch.