Completed
Push — master ( 5061b6...54eaec )
by Michael
12:20 queued 12:16
created
xoops_lib/Xoops/Core/Psr4ClassLoader.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -225,8 +225,8 @@
 block discarded – undo
225 225
             // replace namespace separators with directory separators
226 226
             // in the relative class name, append with .php
227 227
             $file = $base_dir
228
-                  . str_replace('\\', '/', $relative_class)
229
-                  . '.php';
228
+                    . str_replace('\\', '/', $relative_class)
229
+                    . '.php';
230 230
 
231 231
             // if the mapped file exists, require it
232 232
             if ($this->requireFile($file)) {
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -147,11 +147,11 @@
 block discarded – undo
147 147
     public function addNamespace($prefix, $base_dir, $prepend = false)
148 148
     {
149 149
         // normalize namespace prefix
150
-        $prefix = trim($prefix, '\\') . '\\';
150
+        $prefix = trim($prefix, '\\').'\\';
151 151
 
152 152
         // normalize the base directory with a trailing separator
153
-        $base_dir = rtrim($base_dir, '/') . DIRECTORY_SEPARATOR;
154
-        $base_dir = rtrim($base_dir, DIRECTORY_SEPARATOR) . '/';
153
+        $base_dir = rtrim($base_dir, '/').DIRECTORY_SEPARATOR;
154
+        $base_dir = rtrim($base_dir, DIRECTORY_SEPARATOR).'/';
155 155
 
156 156
         // initialize the namespace prefix array
157 157
         if (isset($this->prefixes[$prefix]) === false) {
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Psr0ClassLoader.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -179,11 +179,11 @@
 block discarded – undo
179 179
                     $this->namespaceSeparator,
180 180
                     DIRECTORY_SEPARATOR,
181 181
                     $namespace
182
-                ) . DIRECTORY_SEPARATOR;
182
+                ).DIRECTORY_SEPARATOR;
183 183
             }
184
-            $fileName .= str_replace('_', DIRECTORY_SEPARATOR, $className) . $this->fileExtension;
184
+            $fileName .= str_replace('_', DIRECTORY_SEPARATOR, $className).$this->fileExtension;
185 185
 
186
-            $absolute = ($this->includePath !== null ? $this->includePath . DIRECTORY_SEPARATOR : '') . $fileName;
186
+            $absolute = ($this->includePath !== null ? $this->includePath.DIRECTORY_SEPARATOR : '').$fileName;
187 187
             if (file_exists($absolute)) {
188 188
                 require $absolute;
189 189
             }
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Events.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -101,12 +101,12 @@  discard block
 block discarded – undo
101 101
             $modules_list = \Xoops::getInstance()->getActiveModules();
102 102
             if (empty($modules_list)) {
103 103
                 // this should only happen if an exception was thrown in setActiveModules()
104
-                $modules_list = array ('system');
104
+                $modules_list = array('system');
105 105
             }
106
-            $this->preloadList =array();
106
+            $this->preloadList = array();
107 107
             $i = 0;
108 108
             foreach ($modules_list as $module) {
109
-                if (is_dir($dir = \XoopsBaseConfig::get('root-path') . "/modules/{$module}/preloads/")) {
109
+                if (is_dir($dir = \XoopsBaseConfig::get('root-path')."/modules/{$module}/preloads/")) {
110 110
                     $file_list = Lists\File::getList($dir);
111 111
                     foreach ($file_list as $file) {
112 112
                         if (preg_match('/(\.php)$/i', $file)) {
@@ -150,10 +150,10 @@  discard block
 block discarded – undo
150 150
     {
151 151
         $xoops = \Xoops::getInstance();
152 152
         foreach ($this->preloadList as $preload) {
153
-            $path = $xoops->path('modules/' . $preload['module'] . '/preloads/' . $preload['file']. '.php');
153
+            $path = $xoops->path('modules/'.$preload['module'].'/preloads/'.$preload['file'].'.php');
154 154
             include_once $path;
155 155
             $class_name = ucfirst($preload['module'])
156
-                . ($preload['file'] === 'preload' ? '' : ucfirst($preload['file']) )
156
+                . ($preload['file'] === 'preload' ? '' : ucfirst($preload['file']))
157 157
                 . 'Preload';
158 158
             if (!class_exists($class_name)) {
159 159
                 continue;
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
     public function addListener($eventName, $callback)
216 216
     {
217 217
         $eventName = $this->toInternalEventName($eventName);
218
-        $this->eventListeners[$eventName][]=$callback;
218
+        $this->eventListeners[$eventName][] = $callback;
219 219
     }
220 220
 
221 221
     /**
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Theme/Factory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@
 block discarded – undo
77 77
             }
78 78
             $xoops->setConfig('theme_set', $options['folderName']);
79 79
         }
80
-        $options['path'] = \XoopsBaseConfig::get('themes-path') . '/' . $options['folderName'];
80
+        $options['path'] = \XoopsBaseConfig::get('themes-path').'/'.$options['folderName'];
81 81
         $inst = new XoopsTheme();
82 82
         foreach ($options as $k => $v) {
83 83
             $inst->$k = $v;
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Theme/Plugins/Blocks.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -187,7 +187,7 @@
 block discarded – undo
187 187
                 : "module:system/system_block_dummy.tpl";
188 188
         //$tplName = str_replace('.html', '.tpl', $tplName);
189 189
 
190
-        $cacheid = $this->generateCacheId('blk_' . $xobject->getVar('bid'));
190
+        $cacheid = $this->generateCacheId('blk_'.$xobject->getVar('bid'));
191 191
 
192 192
         $xoops->events()->triggerEvent(
193 193
             'core.themeblocks.buildblock.start',
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Theme/AdminFactory.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -36,13 +36,13 @@
 block discarded – undo
36 36
         $options["plugins"] = array();
37 37
         $options['renderBanner'] = false;
38 38
         $inst = parent::createInstance($options);
39
-        $inst->path = \XoopsBaseConfig::get('adminthemes-path') . '/' . $inst->folderName;
40
-        $inst->url = \XoopsBaseConfig::get('adminthemes-url') . '/' . $inst->folderName;
39
+        $inst->path = \XoopsBaseConfig::get('adminthemes-path').'/'.$inst->folderName;
40
+        $inst->url = \XoopsBaseConfig::get('adminthemes-url').'/'.$inst->folderName;
41 41
         $inst->template->assign(array(
42
-            'theme_path' => $inst->path, 'theme_tpl' => $inst->path . '/xotpl', 'theme_url' => $inst->url,
43
-            'theme_img'  => $inst->url . '/img', 'theme_icons' => $inst->url . '/icons',
44
-            'theme_css'  => $inst->url . '/css', 'theme_js' => $inst->url . '/js',
45
-            'theme_lang' => $inst->url . '/language',
42
+            'theme_path' => $inst->path, 'theme_tpl' => $inst->path.'/xotpl', 'theme_url' => $inst->url,
43
+            'theme_img'  => $inst->url.'/img', 'theme_icons' => $inst->url.'/icons',
44
+            'theme_css'  => $inst->url.'/css', 'theme_js' => $inst->url.'/js',
45
+            'theme_lang' => $inst->url.'/language',
46 46
         ));
47 47
 
48 48
         return $inst;
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Theme/XoopsTheme.php 2 patches
Spacing   +41 added lines, -41 removed lines patch added patch discarded remove patch
@@ -195,15 +195,15 @@  discard block
 block discarded – undo
195 195
     {
196 196
         $xoops = \Xoops::getInstance();
197 197
         $this->assets = $xoops->assets();
198
-        $this->path = \XoopsBaseConfig::get('themes-path') . '/' . $this->folderName;
199
-        $this->url = \XoopsBaseConfig::get('themes-url') . '/' . $this->folderName;
198
+        $this->path = \XoopsBaseConfig::get('themes-path').'/'.$this->folderName;
199
+        $this->url = \XoopsBaseConfig::get('themes-url').'/'.$this->folderName;
200 200
         $this->template = null;
201 201
         $this->template = new XoopsTpl();
202 202
         //$this->template->currentTheme = $this;
203 203
         $this->template->assignByRef('xoTheme', $this);
204 204
         $this->template->assign(array(
205 205
             'xoops_theme'      => $xoops->getConfig('theme_set'),
206
-            'xoops_imageurl'   => \XoopsBaseConfig::get('themes-url') . '/' . $xoops->getConfig('theme_set') . '/',
206
+            'xoops_imageurl'   => \XoopsBaseConfig::get('themes-url').'/'.$xoops->getConfig('theme_set').'/',
207 207
             'xoops_themecss'   => $xoops->getCss($xoops->getConfig('theme_set')),
208 208
             'xoops_requesturi' => htmlspecialchars($_SERVER['REQUEST_URI'], ENT_QUOTES),
209 209
             'xoops_sitename'   => htmlspecialchars($xoops->getConfig('sitename'), ENT_QUOTES),
@@ -215,10 +215,10 @@  discard block
 block discarded – undo
215 215
                 : htmlspecialchars($xoops->getConfig('slogan'), ENT_QUOTES)
216 216
         ));
217 217
         $this->template->assign(array(
218
-            'theme_path' => $this->path, 'theme_tpl' => $this->path . '/xotpl', 'theme_url' => $this->url,
219
-            'theme_img'  => $this->url . '/img', 'theme_icons' => $this->url . '/icons',
220
-            'theme_css'  => $this->url . '/css', 'theme_js' => $this->url . '/js',
221
-            'theme_lang' => $this->url . '/language',
218
+            'theme_path' => $this->path, 'theme_tpl' => $this->path.'/xotpl', 'theme_url' => $this->url,
219
+            'theme_img'  => $this->url.'/img', 'theme_icons' => $this->url.'/icons',
220
+            'theme_css'  => $this->url.'/css', 'theme_js' => $this->url.'/js',
221
+            'theme_lang' => $this->url.'/language',
222 222
         ));
223 223
 
224 224
         if ($xoops->isUser()) {
@@ -246,7 +246,7 @@  discard block
 block discarded – undo
246 246
             'description', 'keywords', 'robots', 'rating', 'author', 'copyright'
247 247
         );
248 248
         foreach ($metas as $name) {
249
-            $this->addMeta('meta', $name, $xoops->getConfig('meta_' . $name));
249
+            $this->addMeta('meta', $name, $xoops->getConfig('meta_'.$name));
250 250
         }
251 251
 
252 252
         // Other assigns
@@ -285,8 +285,8 @@  discard block
 block discarded – undo
285 285
         //to control order of loading JS and CSS
286 286
         // TODO - this should be done in such a way it can join the base asset
287 287
         //        load above.
288
-        if (\XoopsLoad::fileExists($this->path . "/theme_onload.php")) {
289
-            include_once($this->path . "/theme_onload.php");
288
+        if (\XoopsLoad::fileExists($this->path."/theme_onload.php")) {
289
+            include_once($this->path."/theme_onload.php");
290 290
         }
291 291
 
292 292
         // Instantiate and initialize all the theme plugins
@@ -328,22 +328,22 @@  discard block
 block discarded – undo
328 328
                 $extra_string = $xoops->getConfig('locale');
329 329
                 // Generate group section
330 330
                 if (!$xoops->isUser()) {
331
-                    $extra_string .= '-' . FixedGroups::ANONYMOUS;
331
+                    $extra_string .= '-'.FixedGroups::ANONYMOUS;
332 332
                 } else {
333 333
                     $groups = $xoops->user->getGroups();
334 334
                     sort($groups);
335 335
                     // Generate group string for non-anonymous groups,
336 336
                     // db-pass and db-name (before we find better variables) are used
337 337
                     // to protect group sensitive contents
338
-                    $extra_string .= '-' . substr(md5(implode('-', $groups)), 0, 8) . '-' . substr(md5(
339
-                        \XoopsBaseConfig::get('db-pass') . \XoopsBaseConfig::get('db-name')
338
+                    $extra_string .= '-'.substr(md5(implode('-', $groups)), 0, 8).'-'.substr(md5(
339
+                        \XoopsBaseConfig::get('db-pass').\XoopsBaseConfig::get('db-name')
340 340
                         . \XoopsBaseConfig::get('db-user')
341 341
                     ), 0, 8);
342 342
                 }
343 343
             }
344 344
             $extraString = $extra_string;
345 345
         }
346
-        $cache_id .= '-' . $extraString;
346
+        $cache_id .= '-'.$extraString;
347 347
         return $cache_id;
348 348
     }
349 349
 
@@ -361,9 +361,9 @@  discard block
 block discarded – undo
361 361
             $uri = str_replace(\XoopsBaseConfig::get('url'), '', $_SERVER['REQUEST_URI']);
362 362
             // Clean uri by removing session id
363 363
             if (defined('SID') && SID && strpos($uri, SID)) {
364
-                $uri = preg_replace("/([\?&])(" . SID . "$|" . SID . "&)/", "\\1", $uri);
364
+                $uri = preg_replace("/([\?&])(".SID."$|".SID."&)/", "\\1", $uri);
365 365
             }
366
-            $this->contentCacheId = $this->generateCacheId('page_' . substr(md5($uri), 0, 8));
366
+            $this->contentCacheId = $this->generateCacheId('page_'.substr(md5($uri), 0, 8));
367 367
             if ($this->template->isCached($template, $this->contentCacheId)) {
368 368
                 \Xoops::getInstance()->events()->triggerEvent('core.theme.checkcache.success', array($template, $this));
369 369
                 $this->render(null, null, $template);
@@ -434,7 +434,7 @@  discard block
 block discarded – undo
434 434
 
435 435
         // We assume no overlap between $GLOBALS['xoopsOption']['xoops_module_header'] and
436 436
         // $this->template->getTemplateVars( 'xoops_module_header' ) ?
437
-        $this->template->assign('xoops_module_header', $this->renderMetas(true) . "\n" . $header);
437
+        $this->template->assign('xoops_module_header', $this->renderMetas(true)."\n".$header);
438 438
 
439 439
         if ($canvasTpl) {
440 440
             $this->canvasTemplate = $canvasTpl;
@@ -460,7 +460,7 @@  discard block
 block discarded – undo
460 460
         if (false === (bool)($xoops->getConfig('disable_theme_shortcodes'))) {
461 461
             $this->template->loadFilter('output', 'shortcodes');
462 462
         }
463
-        $this->template->display($this->path . '/' . $this->canvasTemplate);
463
+        $this->template->display($this->path.'/'.$this->canvasTemplate);
464 464
         $this->renderCount++;
465 465
         $xoops->events()->triggerEvent('core.theme.render.end', array($this));
466 466
         return true;
@@ -489,16 +489,16 @@  discard block
 block discarded – undo
489 489
 
490 490
         $language = \XoopsLocale::getLocale();
491 491
         // Load global localization stylesheet if available
492
-        if (\XoopsLoad::fileExists($xoops->path('locale/' . $language . '/style.css'))) {
493
-            $cssAssets[] = $xoops->path('locale/' . $language . '/style.css');
492
+        if (\XoopsLoad::fileExists($xoops->path('locale/'.$language.'/style.css'))) {
493
+            $cssAssets[] = $xoops->path('locale/'.$language.'/style.css');
494 494
         }
495 495
         //$this->addLanguage($type);
496 496
         // Load theme localization stylesheet and scripts if available
497
-        if (\XoopsLoad::fileExists($this->path . '/locale/' . $language . '/script.js')) {
498
-            $jsAssets[] = $this->url . '/locale/' . $language . '/script.js';
497
+        if (\XoopsLoad::fileExists($this->path.'/locale/'.$language.'/script.js')) {
498
+            $jsAssets[] = $this->url.'/locale/'.$language.'/script.js';
499 499
         }
500
-        if (\XoopsLoad::fileExists($this->path . '/locale/' . $language . '/style.css')) {
501
-            $cssAssets[] = $this->path . '/locale/' . $language . '/style.css';
500
+        if (\XoopsLoad::fileExists($this->path.'/locale/'.$language.'/style.css')) {
501
+            $cssAssets[] = $this->path.'/locale/'.$language.'/style.css';
502 502
         }
503 503
         return array($cssAssets, $jsAssets);
504 504
     }
@@ -642,7 +642,7 @@  discard block
 block discarded – undo
642 642
     public function addBaseAssets($type, $assets)
643 643
     {
644 644
         if (is_scalar($assets)) {
645
-            $this->baseAssets[$type][]=$assets;
645
+            $this->baseAssets[$type][] = $assets;
646 646
         } elseif (is_array($assets)) {
647 647
             $this->baseAssets[$type] = array_merge($this->baseAssets[$type], $assets);
648 648
         }
@@ -809,14 +809,14 @@  discard block
 block discarded – undo
809 809
         if (!empty($this->baseAssets['js'])) {
810 810
             $url = $this->assets->getUrlToAssets('js', $this->baseAssets['js']);
811 811
             if (!empty($url)) {
812
-                $str .= '<script src="' . $url . '" type="text/javascript"></script>'."\n";
812
+                $str .= '<script src="'.$url.'" type="text/javascript"></script>'."\n";
813 813
             }
814 814
         }
815 815
 
816 816
         if (!empty($this->baseAssets['css'])) {
817 817
             $url = $this->assets->getUrlToAssets('css', $this->baseAssets['css']);
818 818
             if (!empty($url)) {
819
-                $str .= '<link rel="stylesheet" href="' . $url . '" type="text/css" />'."\n";
819
+                $str .= '<link rel="stylesheet" href="'.$url.'" type="text/css" />'."\n";
820 820
             }
821 821
         }
822 822
         return $str;
@@ -839,9 +839,9 @@  discard block
 block discarded – undo
839 839
         switch ($type) {
840 840
             case 'script':
841 841
                 foreach ($this->metas[$type] as $attrs) {
842
-                    $str .= "<script" . $this->renderAttributes($attrs) . ">";
842
+                    $str .= "<script".$this->renderAttributes($attrs).">";
843 843
                     if (@$attrs['_']) {
844
-                        $str .= "\n//<![CDATA[\n" . $attrs['_'] . "\n//]]>";
844
+                        $str .= "\n//<![CDATA[\n".$attrs['_']."\n//]]>";
845 845
                     }
846 846
                     $str .= "</script>\n";
847 847
                 }
@@ -850,29 +850,29 @@  discard block
 block discarded – undo
850 850
                 foreach ($this->metas[$type] as $attrs) {
851 851
                     $rel = $attrs['rel'];
852 852
                     unset($attrs['rel']);
853
-                    $str .= '<link rel="' . $rel . '"' . $this->renderAttributes($attrs) . " />\n";
853
+                    $str .= '<link rel="'.$rel.'"'.$this->renderAttributes($attrs)." />\n";
854 854
                 }
855 855
                 break;
856 856
             case 'stylesheet':
857 857
                 foreach ($this->metas[$type] as $attrs) {
858 858
                     if (@$attrs['_']) {
859
-                        $str .= '<style' . $this->renderAttributes($attrs)
860
-                            . ">\n/* <![CDATA[ */\n" . $attrs['_'] . "\n/* //]]> */\n</style>";
859
+                        $str .= '<style'.$this->renderAttributes($attrs)
860
+                            . ">\n/* <![CDATA[ */\n".$attrs['_']."\n/* //]]> */\n</style>";
861 861
                     } else {
862
-                        $str .= '<link rel="stylesheet"' . $this->renderAttributes($attrs) . " />\n";
862
+                        $str .= '<link rel="stylesheet"'.$this->renderAttributes($attrs)." />\n";
863 863
                     }
864 864
                 }
865 865
                 break;
866 866
             case 'http':
867 867
                 foreach ($this->metas[$type] as $name => $content) {
868
-                    $str .= '<meta http-equiv="' . htmlspecialchars($name, ENT_QUOTES) . '" content="'
869
-                        . htmlspecialchars($content, ENT_QUOTES) . "\" />\n";
868
+                    $str .= '<meta http-equiv="'.htmlspecialchars($name, ENT_QUOTES).'" content="'
869
+                        . htmlspecialchars($content, ENT_QUOTES)."\" />\n";
870 870
                 }
871 871
                 break;
872 872
             default:
873 873
                 foreach ($this->metas[$type] as $name => $content) {
874
-                    $str .= '<meta name="' . htmlspecialchars($name, ENT_QUOTES) . '" content="'
875
-                        . htmlspecialchars($content, ENT_QUOTES) . "\" />\n";
874
+                    $str .= '<meta name="'.htmlspecialchars($name, ENT_QUOTES).'" content="'
875
+                        . htmlspecialchars($content, ENT_QUOTES)."\" />\n";
876 876
                 }
877 877
                 break;
878 878
         }
@@ -893,7 +893,7 @@  discard block
 block discarded – undo
893 893
         if (!isset($cache[$tagName])) {
894 894
             $cache[$tagName] = 1;
895 895
         }
896
-        return $tagName . '-' . $cache[$tagName]++;
896
+        return $tagName.'-'.$cache[$tagName]++;
897 897
     }
898 898
 
899 899
     /**
@@ -908,7 +908,7 @@  discard block
 block discarded – undo
908 908
         $str = '';
909 909
         foreach ($coll as $name => $val) {
910 910
             if ($name !== '_') {
911
-                $str .= ' ' . $name . '="' . htmlspecialchars($val, ENT_QUOTES) . '"';
911
+                $str .= ' '.$name.'="'.htmlspecialchars($val, ENT_QUOTES).'"';
912 912
             }
913 913
         }
914 914
         return $str;
@@ -928,12 +928,12 @@  discard block
 block discarded – undo
928 928
         }
929 929
         $xoops_root_path = \XoopsBaseConfig::get('root-path');
930 930
 //\Xoops::getInstance()->events()->triggerEvent('debug.log', $this);
931
-        if (\XoopsLoad::fileExists($xoops_root_path . "/{$this->themesPath}/{$this->folderName}/{$path}")) {
931
+        if (\XoopsLoad::fileExists($xoops_root_path."/{$this->themesPath}/{$this->folderName}/{$path}")) {
932 932
 //\Xoops::getInstance()->events()->triggerEvent('debug.log', "custom theme path {$this->themesPath}/{$this->folderName}/{$path}");
933 933
             return "{$this->themesPath}/{$this->folderName}/{$path}";
934 934
         }
935 935
 
936
-        if (\XoopsLoad::fileExists($xoops_root_path . "/themes/{$this->folderName}/{$path}")) {
936
+        if (\XoopsLoad::fileExists($xoops_root_path."/themes/{$this->folderName}/{$path}")) {
937 937
 //\Xoops::getInstance()->events()->triggerEvent('debug.log', "main theme folder themes/{$this->folderName}/{$path}");
938 938
             return "themes/{$this->folderName}/{$path}";
939 939
         }
Please login to merge, or discard this patch.
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -174,12 +174,12 @@  discard block
 block discarded – undo
174 174
      */
175 175
     public $headersCacheEngine = 'default';
176 176
 	
177
-	/**
177
+    /**
178 178
      * 
179 179
      *$renderer instance of renderer
180 180
      * 
181 181
      */	
182
-	protected $renderer;
182
+    protected $renderer;
183 183
 
184 184
     /**
185 185
      * *#@-
@@ -321,10 +321,10 @@  discard block
 block discarded – undo
321 321
      */
322 322
     public function setRenderer($renderer)
323 323
     {
324
-		$this->renderer = $renderer;
324
+        $this->renderer = $renderer;
325 325
     }
326 326
 	
327
-	/**
327
+    /**
328 328
      * get the renderer
329 329
      *
330 330
      * @return Renderer
@@ -333,10 +333,10 @@  discard block
 block discarded – undo
333 333
     {
334 334
         // return a default if not set
335 335
         if (null === $this->renderer) {
336
-			return $element->defaultRender();
337
-		} else {
338
-			return $this->renderer->render($element);
339
-		}
336
+            return $element->defaultRender();
337
+        } else {
338
+            return $this->renderer->render($element);
339
+        }
340 340
     }
341 341
 
342 342
     /**
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Database/Connection.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
      */
81 81
     public function setForce($force = false)
82 82
     {
83
-        $this->force = (bool) $force;
83
+        $this->force = (bool)$force;
84 84
     }
85 85
 
86 86
     /**
@@ -135,7 +135,7 @@  discard block
 block discarded – undo
135 135
     {
136 136
         $prefix = \XoopsBaseConfig::get('db-prefix');
137 137
         if ($tablename != '') {
138
-            return $prefix . '_' . $tablename;
138
+            return $prefix.'_'.$tablename;
139 139
         } else {
140 140
             return $prefix;
141 141
         }
@@ -257,14 +257,14 @@  discard block
 block discarded – undo
257 257
             $events->triggerEvent('core.database.query.end');
258 258
         } else {
259 259
             //$events->triggerEvent('core.database.query.failure', (array('Not safe:')));
260
-            return (int) 0;
260
+            return (int)0;
261 261
         }
262 262
         if ($result != 0) {
263 263
             //$events->triggerEvent('core.database.query.success', (array($query)));
264
-            return (int) $result;
264
+            return (int)$result;
265 265
         } else {
266 266
             //$events->triggerEvent('core.database.query.failure', (array($query)));
267
-            return (int) 0;
267
+            return (int)0;
268 268
         }
269 269
     }
270 270
 
@@ -331,7 +331,7 @@  discard block
 block discarded – undo
331 331
             $result = call_user_func_array(array('parent', 'query'), func_get_args());
332 332
         } catch (\Exception $e) {
333 333
             $events->triggerEvent('core.exception', $e);
334
-            $result=null;
334
+            $result = null;
335 335
         }
336 336
         $events->triggerEvent('core.database.query.end');
337 337
         if ($result) {
Please login to merge, or discard this patch.
xoops_lib/Xoops/Core/Database/Schema/ExportVisitor.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -105,7 +105,7 @@
 block discarded – undo
105 105
     public function acceptForeignKey(Table $localTable, ForeignKeyConstraint $fkConstraint)
106 106
     {
107 107
         if (!isset($this->schemaArray['tables'][$localTable->getName()]['constraint'])) {
108
-            $this->schemaArray['tables'][$localTable->getName()]['constraint']=array();
108
+            $this->schemaArray['tables'][$localTable->getName()]['constraint'] = array();
109 109
         }
110 110
         $this->schemaArray['tables'][$localTable->getName()]['constraint'][] = array(
111 111
                 'name' => $fkConstraint->getName(),
Please login to merge, or discard this patch.