Test Failed
Push — 1.0.0-dev ( 252b0d...ee03cc )
by nguereza
02:32
created
core/classes/Lang.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@
 block discarded – undo
79 79
             if ($cookieLang && $this->isValid($cookieLang)) {
80 80
                 $this->current = $cookieLang;
81 81
                 $this->logger->info('Language from cookie [' . $cfgKey . '] is valid so '
82
-                                     .'we will set the language using the cookie value [' . $cookieLang . ']');
82
+                                        .'we will set the language using the cookie value [' . $cookieLang . ']');
83 83
             } else {
84 84
                 $this->logger->info('Language from cookie [' . $cfgKey . '] is not set, use the default value [' . $this->getDefault() . ']');
85 85
                 $this->current = $this->getDefault();
Please login to merge, or discard this patch.
core/classes/Loader.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -219,7 +219,7 @@  discard block
 block discarded – undo
219 219
             $moduleConfigPath = get_instance()->module->findConfigFullPath($filename, $module);
220 220
             if ($moduleConfigPath) {
221 221
                 $this->logger->info('Found config [' . $filename . '] from module [' . $module . '], '
222
-                                  . 'the file path is [' . $moduleConfigPath . '] we will used it');
222
+                                    . 'the file path is [' . $moduleConfigPath . '] we will used it');
223 223
                 $configFilePath = $moduleConfigPath;
224 224
             } else {
225 225
                 $this->logger->info('Cannot find config [' . $filename . '] from modules using the default location');
@@ -479,7 +479,7 @@  discard block
 block discarded – undo
479 479
             $moduleLibraryPath = get_instance()->module->findLibraryFullPath($class, $module);
480 480
             if ($moduleLibraryPath) {
481 481
                 $this->logger->info('Found library [' . $class . '] from module [' . $module . '], the '
482
-                                   . 'file path is [' . $moduleLibraryPath . '] we will used it');
482
+                                    . 'file path is [' . $moduleLibraryPath . '] we will used it');
483 483
                 $libraryFilePath = $moduleLibraryPath;
484 484
             } else {
485 485
                 $this->logger->info('Cannot find library [' . $class . '] from modules using the default location');
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -335,7 +335,7 @@  discard block
 block discarded – undo
335 335
          * @param  string $appLang the application language, only if type = "language"
336 336
          * @return string|null          the full file path
337 337
          */
338
-        protected function getDefaultFilePathForFunctionLanguage($file, $type, $appLang = null){
338
+        protected function getDefaultFilePathForFunctionLanguage($file, $type, $appLang = null) {
339 339
             //Default to "function"
340 340
             $searchDir = array(FUNCTIONS_PATH, CORE_FUNCTIONS_PATH);
341 341
             if ($type == 'language') {
@@ -359,7 +359,7 @@  discard block
 block discarded – undo
359 359
          * @param  string|null $module the module if is not null will return it
360 360
          * @return string|null
361 361
          */
362
-        protected function getModuleFromSuperController($module){
362
+        protected function getModuleFromSuperController($module) {
363 363
             $obj = & get_instance();
364 364
             if (!$module && !empty($obj->moduleName)) {
365 365
                 $module = $obj->moduleName;
Please login to merge, or discard this patch.
core/classes/model/DBSessionHandlerModel.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -29,8 +29,8 @@  discard block
 block discarded – undo
29 29
      */
30 30
 	
31 31
     /**
32
-    * DB session handler model class
33
-    */
32
+     * DB session handler model class
33
+     */
34 34
     abstract class DBSessionHandlerModel extends Model {
35 35
 		
36 36
         /**
@@ -40,14 +40,14 @@  discard block
 block discarded – undo
40 40
          *
41 41
          * @example
42 42
          * 	array(
43
-	 *	      'sid' => '', //VARCHAR(100) Note: this a primary key
44
-	 *	      'sdata' => '', //TEXT
45
-	 *	      'stime' => '', //unix timestamp (INT|BIGINT)
46
-	 *	      'shost' => '', //VARCHAR(255)
47
-	 *	      'sip' => '', //VARCHAR(128) 
48
-	 *	      'sbrowser' => '', //VARCHAR(255) 
49
-	 *	      'skey' => '' //VARCHAR(255) 
50
-	 *	);
43
+         *	      'sid' => '', //VARCHAR(100) Note: this a primary key
44
+         *	      'sdata' => '', //TEXT
45
+         *	      'stime' => '', //unix timestamp (INT|BIGINT)
46
+         *	      'shost' => '', //VARCHAR(255)
47
+         *	      'sip' => '', //VARCHAR(128) 
48
+         *	      'sbrowser' => '', //VARCHAR(255) 
49
+         *	      'skey' => '' //VARCHAR(255) 
50
+         *	);
51 51
          */
52 52
         protected $sessionTableColumns = array();
53 53
 
Please login to merge, or discard this patch.
core/classes/Config.php 1 patch
Indentation   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -46,9 +46,9 @@  discard block
 block discarded – undo
46 46
             if ($init) {
47 47
                 $this->init();
48 48
                 //@codeCoverageIgnoreStart
49
-                 if (ENVIRONMENT == 'production' && in_array(strtolower($this->config['log_level']), array('debug', 'info', 'notice'))) {
49
+                    if (ENVIRONMENT == 'production' && in_array(strtolower($this->config['log_level']), array('debug', 'info', 'notice'))) {
50 50
                     $this->logger->warning('You are in production environment, please set '
51
-                                           . 'log level to WARNING, ERROR, CRITICAL, ALERT, EMERGENCY to increase the application performance');
51
+                                            . 'log level to WARNING, ERROR, CRITICAL, ALERT, EMERGENCY to increase the application performance');
52 52
                 }
53 53
                 //@codeCoverageIgnoreEnd
54 54
             }
@@ -146,7 +146,7 @@  discard block
 block discarded – undo
146 146
             if (empty($this->config['base_url'])) {
147 147
                 if (ENVIRONMENT == 'production') {
148 148
                     $this->logger->warning('Application base URL is not set or invalid, please'
149
-                                           . ' set application base URL to increase the application loading time');
149
+                                            . ' set application base URL to increase the application loading time');
150 150
                 }
151 151
                 $baseUrl = null;
152 152
                 $protocol = 'http';
@@ -173,7 +173,7 @@  discard block
 block discarded – undo
173 173
                                                                     );
174 174
                 } else {
175 175
                     $this->logger->warning('Can not determine the application '
176
-                                           . 'base URL automatically, use http://localhost as default');
176
+                                            . 'base URL automatically, use http://localhost as default');
177 177
                     $baseUrl = 'http://localhost/';
178 178
                 }
179 179
                 $this->config['base_url'] = $baseUrl;
@@ -182,11 +182,11 @@  discard block
 block discarded – undo
182 182
         }
183 183
          
184 184
         /**
185
-        * Return the server port using variable
186
-        *
187
-        * @codeCoverageIgnore
188
-        * @return string
189
-        */
185
+         * Return the server port using variable
186
+         *
187
+         * @codeCoverageIgnore
188
+         * @return string
189
+         */
190 190
         protected function getServerPort() {
191 191
             $globals = & class_loader('GlobalVar', 'classes');
192 192
             $serverPort = $globals->server('SERVER_PORT');
Please login to merge, or discard this patch.
core/classes/DBSessionHandler.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -318,7 +318,7 @@
 block discarded – undo
318 318
          * Get some parameters need like ip address, hostname, browser info, etc.
319 319
          * @return array
320 320
          */
321
-        protected function getSessionDataParams(){
321
+        protected function getSessionDataParams() {
322 322
             $this->OBJ->loader->functions('user_agent'); 
323 323
             $this->OBJ->loader->library('Browser'); 
324 324
             
Please login to merge, or discard this patch.
core/classes/Router.php 2 patches
Indentation   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -276,14 +276,14 @@  discard block
 block discarded – undo
276 276
         }
277 277
 
278 278
         /**
279
-        * Setting the route configuration using the configuration file 
280
-        * and additional configuration from param
281
-        * @param array $overwriteConfig the additional configuration 
282
-        * to overwrite with the existing one
283
-        * @param boolean $useConfigFile whether to use route configuration file
284
-        * 
285
-        * @return object
286
-        */
279
+         * Setting the route configuration using the configuration file 
280
+         * and additional configuration from param
281
+         * @param array $overwriteConfig the additional configuration 
282
+         * to overwrite with the existing one
283
+         * @param boolean $useConfigFile whether to use route configuration file
284
+         * 
285
+         * @return object
286
+         */
287 287
         public function setRouteConfiguration(array $overwriteConfig = array(), $useConfigFile = true) {
288 288
             $route = array();
289 289
             if ($useConfigFile && file_exists(CONFIG_PATH . 'routes.php')) {
@@ -364,7 +364,7 @@  discard block
 block discarded – undo
364 364
             //the URL like http://domain.com/module/controller/method/arg1/arg2/argn 
365 365
             if (!$this->controller) {
366 366
                 $this->logger->info('Cannot determine the routing information ' 
367
-                       . 'using the predefined routes configuration, will use the request URI parameters');
367
+                        . 'using the predefined routes configuration, will use the request URI parameters');
368 368
                 //determine route parameters using the route URI param
369 369
                 $this->determineRouteParamsFromRequestUri();
370 370
             }
@@ -478,11 +478,11 @@  discard block
 block discarded – undo
478 478
             }
479 479
         }
480 480
 
481
-         /**
482
-         * Remove the URL suffix and query string values if exists
483
-         * @param  string $uri the route URI to process
484
-         * @return string      the final route uri after processed
485
-         */
481
+            /**
482
+             * Remove the URL suffix and query string values if exists
483
+             * @param  string $uri the route URI to process
484
+             * @return string      the final route uri after processed
485
+             */
486 486
         protected function removeSuffixAndQueryStringFromUri($uri) {
487 487
             $this->logger->debug('Check if URL suffix is enabled in the configuration');
488 488
             //remove url suffix from the request URI
@@ -598,7 +598,7 @@  discard block
 block discarded – undo
598 598
                 $this->logger->info(
599 599
                                     'After loop in predefined routes configuration,'
600 600
                                     . 'the module name is set but the controller is not set,' 
601
-									. 'so we will use module as the controller'
601
+                                    . 'so we will use module as the controller'
602 602
                                 );
603 603
                 $this->controller = $this->module;
604 604
             }
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -450,7 +450,7 @@  discard block
 block discarded – undo
450 450
          * Remove the DOCUMENT_ROOT and front controller from segments if exists
451 451
          * @return void
452 452
          */
453
-        protected function removeDocumentRootFrontControllerFromSegments(){
453
+        protected function removeDocumentRootFrontControllerFromSegments() {
454 454
             $segment = $this->segments;
455 455
             $globals = & class_loader('GlobalVar', 'classes');
456 456
             $rootFolder = substr($globals->server('SCRIPT_NAME'), 0, strpos(
@@ -581,7 +581,7 @@  discard block
 block discarded – undo
581 581
                     break;
582 582
                 }
583 583
             }
584
-            if($findIndex !== -1){
584
+            if ($findIndex !== -1) {
585 585
                 /*
586 586
                 * $args[0] => full string captured by preg_match
587 587
                 * $args[1], $args[2], $args[n] => contains the value of 
@@ -608,7 +608,7 @@  discard block
 block discarded – undo
608 608
          * Find file path of the current controller using the current module
609 609
          * @return boolean true if the file path is found otherwise false.
610 610
          */
611
-        protected function findControllerFullPathUsingCurrentModule(){
611
+        protected function findControllerFullPathUsingCurrentModule() {
612 612
             $path = $this->moduleInstance->findControllerFullPath(ucfirst($this->controller), $this->module);
613 613
             if (!$path) {
614 614
                 $this->logger->info('The controller [' . $this->controller . '] not ' 
@@ -625,7 +625,7 @@  discard block
 block discarded – undo
625 625
          * or the current request does not use module
626 626
          * @return void
627 627
          */
628
-        protected function setRouteParamsIfNoModuleOrNotFound(){
628
+        protected function setRouteParamsIfNoModuleOrNotFound() {
629 629
             $segment = $this->segments;
630 630
             //controller
631 631
             if (isset($segment[0])) {
@@ -646,7 +646,7 @@  discard block
 block discarded – undo
646 646
          * or the current request use module
647 647
          * @return void
648 648
          */
649
-        protected function setRouteParamsIfAppHasModuleOrFound(){
649
+        protected function setRouteParamsIfAppHasModuleOrFound() {
650 650
             //get the module list
651 651
             $modules = $this->moduleInstance->getModuleList();
652 652
             $segment = $this->segments;
@@ -658,7 +658,7 @@  discard block
 block discarded – undo
658 658
                 if (isset($segment[0])) {
659 659
                     $this->controller = $segment[0];
660 660
                     //check if the request use the same module name and controller
661
-                    if($this->findControllerFullPathUsingCurrentModule()){
661
+                    if ($this->findControllerFullPathUsingCurrentModule()) {
662 662
                         array_shift($segment);
663 663
                     }
664 664
                 }
Please login to merge, or discard this patch.