Completed
Push — develop ( 0c0e51 )
by Adam
26:01 queued 12:43
created
include/generic/SugarWidgets/SugarWidgetSubPanelActivitiesStatusField.php 1 patch
Braces   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -56,8 +58,7 @@  discard block
 block discarded – undo
56 58
 		if(isset($layout_def['varname']))
57 59
 		{
58 60
 			$key = strtoupper($layout_def['varname']);
59
-		}
60
-		else
61
+		} else
61 62
 		{
62 63
 			$key = $this->_get_column_alias($layout_def);
63 64
 			$key = strtoupper($key);
Please login to merge, or discard this patch.
include/generic/SugarWidgets/SugarWidgetFieldcurrency_id.php 1 patch
Braces   +6 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -58,8 +60,7 @@  discard block
 block discarded – undo
58 60
             if (is_array($list))
59 61
             {
60 62
                 $list = array_merge(array($currency), $list);
61
-            }
62
-            else
63
+            } else
63 64
             {
64 65
                 $list = array($currency);
65 66
             }
@@ -105,8 +106,7 @@  discard block
 block discarded – undo
105 106
         if (!empty ($field_def['sort_on']))
106 107
         {
107 108
             $order_by = $layout_def['table_alias'].".".$field_def['sort_on'];
108
-        }
109
-        else
109
+        } else
110 110
         {
111 111
             $order_by = $this->_get_column_select($layout_def);
112 112
         }
@@ -114,8 +114,7 @@  discard block
 block discarded – undo
114 114
         if (empty ($layout_def['sort_dir']) || $layout_def['sort_dir'] == 'a')
115 115
         {
116 116
             $order_dir = "ASC";
117
-        }
118
-        else
117
+        } else
119 118
         {
120 119
             $order_dir = "DESC";
121 120
         }
Please login to merge, or discard this patch.
include/generic/SugarWidgets/SugarWidgetFieldbool.php 1 patch
Braces   +6 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -69,8 +71,7 @@  discard block
 block discarded – undo
69 71
             global $app_list_strings;
70 72
             if (empty($value)) {
71 73
                 $value = $app_list_strings['dom_switch_bool']['off'];
72
-            }   
73
-            else {
74
+            } else {
74 75
                 $value = $app_list_strings['dom_switch_bool']['on'];
75 76
             } 
76 77
             return $value;
@@ -97,11 +98,9 @@  discard block
 block discarded – undo
97 98
         $yes = $no = $default = '';
98 99
         if (isset($layout_def['input_name0']) && $layout_def['input_name0'] == 1) {
99 100
             $yes = ' selected="selected"';
100
-        }
101
-        elseif (isset($layout_def['input_name0']) && $layout_def['input_name0'] == 'off') {
101
+        } elseif (isset($layout_def['input_name0']) && $layout_def['input_name0'] == 'off') {
102 102
             $no = ' selected="selected"';
103
-        }
104
-        else {
103
+        } else {
105 104
             $default = ' selected="selected"';
106 105
         }
107 106
         
Please login to merge, or discard this patch.
generic/SugarWidgets/SugarWidgetSubPanelTopCreateAccountNameButton.php 1 patch
Braces   +21 added lines, -13 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -65,18 +67,24 @@  discard block
 block discarded – undo
65 67
 		}
66 68
 		
67 69
 		$additionalFormFields = array();
68
-		if(isset($defines['focus']->billing_address_street)) 
69
-			$additionalFormFields['primary_address_street'] = $defines['focus']->billing_address_street;
70
-		if(isset($defines['focus']->billing_address_city)) 
71
-			$additionalFormFields['primary_address_city'] = $defines['focus']->billing_address_city;						  		
72
-		if(isset($defines['focus']->billing_address_state)) 
73
-			$additionalFormFields['primary_address_state'] = $defines['focus']->billing_address_state;
74
-		if(isset($defines['focus']->billing_address_country)) 
75
-			$additionalFormFields['primary_address_country'] = $defines['focus']->billing_address_country;
76
-		if(isset($defines['focus']->billing_address_postalcode)) 
77
-			$additionalFormFields['primary_address_postalcode'] = $defines['focus']->billing_address_postalcode;
78
-		if(isset($defines['focus']->phone_office)) 
79
-			$additionalFormFields['phone_work'] = $defines['focus']->phone_office;
70
+		if(isset($defines['focus']->billing_address_street)) {
71
+					$additionalFormFields['primary_address_street'] = $defines['focus']->billing_address_street;
72
+		}
73
+		if(isset($defines['focus']->billing_address_city)) {
74
+					$additionalFormFields['primary_address_city'] = $defines['focus']->billing_address_city;
75
+		}
76
+		if(isset($defines['focus']->billing_address_state)) {
77
+					$additionalFormFields['primary_address_state'] = $defines['focus']->billing_address_state;
78
+		}
79
+		if(isset($defines['focus']->billing_address_country)) {
80
+					$additionalFormFields['primary_address_country'] = $defines['focus']->billing_address_country;
81
+		}
82
+		if(isset($defines['focus']->billing_address_postalcode)) {
83
+					$additionalFormFields['primary_address_postalcode'] = $defines['focus']->billing_address_postalcode;
84
+		}
85
+		if(isset($defines['focus']->phone_office)) {
86
+					$additionalFormFields['phone_work'] = $defines['focus']->phone_office;
87
+		}
80 88
 		
81 89
 		
82 90
 		$button = $this->_get_form($defines, $additionalFormFields);
Please login to merge, or discard this patch.
include/generic/SugarWidgets/SugarWidgetSubPanelRemoveButtonMeetings.php 1 patch
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -111,7 +113,7 @@  discard block
 block discarded – undo
111 113
 		if($layout_def['ListView']) {
112 114
             return "<a href=\"javascript:sub_p_rem('$subpanel', '$linked_field'" .", '$record', $refresh_page);\""
113 115
 			        . ' class="listViewTdToolsS1"' . " onclick=\"return sp_rem_conf();\"" . ">$icon_remove_text</a>";
114
-		}else{
116
+		} else{
115 117
 			return '';
116 118
 		}
117 119
 	}
Please login to merge, or discard this patch.
include/generic/SugarWidgets/SugarWidgetSubPanelIcon.php 1 patch
Braces   +6 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -59,8 +61,7 @@  discard block
 block discarded – undo
59 61
 		if(isset($layout_def['varname']))
60 62
 		{
61 63
 			$key = strtoupper($layout_def['varname']);
62
-		}
63
-		else
64
+		} else
64 65
 		{
65 66
 			$key = $this->_get_column_alias($layout_def);
66 67
 			$key = strtoupper($key);
@@ -77,8 +78,7 @@  discard block
 block discarded – undo
77 78
 			if(empty($layout_def['target_module']))
78 79
 			{
79 80
 				$module = $layout_def['module'];
80
-			}
81
-		else
81
+			} else
82 82
 			{
83 83
 				$module = $layout_def['target_module'];
84 84
 			}
@@ -87,8 +87,7 @@  discard block
 block discarded – undo
87 87
 		if(empty($layout_def['target_record_key']))
88 88
 		{
89 89
 			$record = $layout_def['fields']['ID'];
90
-		}
91
-		else
90
+		} else
92 91
 		{
93 92
 			$record_key = strtoupper($layout_def['target_record_key']);
94 93
 			$record = $layout_def['fields'][$record_key];
Please login to merge, or discard this patch.
include/generic/SugarWidgets/SugarWidgetSubPanelRemoveButton.php 1 patch
Braces   +7 added lines, -4 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -106,8 +108,9 @@  discard block
 block discarded – undo
106 108
 
107 109
 		$icon_remove_text = mb_strtolower($app_strings['LBL_ID_FF_REMOVE'], 'UTF-8');
108 110
 		
109
-         if($linked_field == 'get_emails_by_assign_or_link')
110
-            $linked_field = 'emails';
111
+         if($linked_field == 'get_emails_by_assign_or_link') {
112
+                     $linked_field = 'emails';
113
+         }
111 114
 		//based on listview since that lets you select records
112 115
 		if($layout_def['ListView'] && !$hideremove) {
113 116
             $retStr = "<a href=\"javascript:sub_p_rem('$subpanel', '$linked_field'" 
@@ -118,7 +121,7 @@  discard block
 block discarded – undo
118 121
 			. ">$icon_remove_text</a>";
119 122
         return $retStr;
120 123
             
121
-		}else{
124
+		} else{
122 125
 			return '';
123 126
 		}
124 127
 	}
Please login to merge, or discard this patch.
include/generic/DeleteRelationship.php 1 patch
Braces   +7 added lines, -5 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -81,13 +83,13 @@  discard block
 block discarded – undo
81 83
  {
82 84
  	$focus->retrieve($record);
83 85
  	$focus->remove_user_from_team($linked_id);
84
- }
85
- else
86
+ } else
86 87
  {
87 88
  	// cut it off:
88 89
  	$focus->load_relationship($linked_field);
89
- 	if($focus->$linked_field->_relationship->relationship_name == 'quotes_contacts_shipto')
90
- 		unset($focus->$linked_field->_relationship->relationship_role_column);
90
+ 	if($focus->$linked_field->_relationship->relationship_name == 'quotes_contacts_shipto') {
91
+ 	 		unset($focus->$linked_field->_relationship->relationship_role_column);
92
+ 	}
91 93
  	$focus->$linked_field->delete($record,$linked_id);
92 94
  }
93 95
  if ($bean_name == 'Campaign' and $linked_field=='prospectlists' ) {
Please login to merge, or discard this patch.
include/SugarTheme/SugarTheme.php 1 patch
Braces   +216 added lines, -158 removed lines patch added patch discarded remove patch
@@ -1,5 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
2
+if(!defined('sugarEntry') || !sugarEntry) {
3
+    die('Not A Valid Entry Point');
4
+}
3 5
 /*********************************************************************************
4 6
  * SugarCRM Community Edition is a customer relationship management program developed by
5 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -46,8 +48,9 @@  discard block
 block discarded – undo
46 48
  * theme basis.
47 49
  ********************************************************************************/
48 50
 
49
-if(!defined('JSMIN_AS_LIB'))
51
+if(!defined('JSMIN_AS_LIB')) {
50 52
     define('JSMIN_AS_LIB', true);
53
+}
51 54
 
52 55
 require_once("include/SugarTheme/cssmin.php");
53 56
 require_once("jssource/jsmin.php");
@@ -299,10 +302,11 @@  discard block
 block discarded – undo
299 302
                 if ( property_exists(__CLASS__,$key) ) {
300 303
                     // For all arrays ( except colors and fonts ) you can just specify the items
301 304
                     // to change instead of all of the values
302
-                    if ( is_array($this->$key) && !in_array($key,array('colors','fonts')) )
303
-                        $this->$key = array_merge($this->$key,$value);
304
-                    else
305
-                        $this->$key = $value;
305
+                    if ( is_array($this->$key) && !in_array($key,array('colors','fonts')) ) {
306
+                                            $this->$key = array_merge($this->$key,$value);
307
+                    } else {
308
+                                            $this->$key = $value;
309
+                    }
306 310
                 }
307 311
             }
308 312
         }
@@ -310,23 +314,28 @@  discard block
 block discarded – undo
310 314
             if ( property_exists(__CLASS__,$key) ) {
311 315
                 // For all arrays ( except colors and fonts ) you can just specify the items
312 316
                 // to change instead of all of the values
313
-                if ( is_array($this->$key) && !in_array($key,array('colors','fonts')) )
314
-                    $this->$key = array_merge($this->$key,$value);
315
-                else
316
-                    $this->$key = $value;
317
+                if ( is_array($this->$key) && !in_array($key,array('colors','fonts')) ) {
318
+                                    $this->$key = array_merge($this->$key,$value);
319
+                } else {
320
+                                    $this->$key = $value;
321
+                }
317 322
             }
318 323
         }
319 324
         if ( !inDeveloperMode() ) {
320 325
             if ( sugar_is_file($cachedfile = sugar_cached($this->getFilePath().'/pathCache.php'))) {
321 326
                 $caches = unserialize(file_get_contents($cachedfile));
322
-                if ( isset($caches['jsCache']) )
323
-                    $this->_jsCache       = $caches['jsCache'];
324
-                if ( isset($caches['cssCache']) )
325
-                    $this->_cssCache      = $caches['cssCache'];
326
-                if ( isset($caches['imageCache']) )
327
-                    $this->_imageCache    = $caches['imageCache'];
328
-                if ( isset($caches['templateCache']) )
329
-                    $this->_templateCache = $caches['templateCache'];
327
+                if ( isset($caches['jsCache']) ) {
328
+                                    $this->_jsCache       = $caches['jsCache'];
329
+                }
330
+                if ( isset($caches['cssCache']) ) {
331
+                                    $this->_cssCache      = $caches['cssCache'];
332
+                }
333
+                if ( isset($caches['imageCache']) ) {
334
+                                    $this->_imageCache    = $caches['imageCache'];
335
+                }
336
+                if ( isset($caches['templateCache']) ) {
337
+                                    $this->_templateCache = $caches['templateCache'];
338
+                }
330 339
             }
331 340
             $cachedfile = sugar_cached($this->getFilePath().'/spriteCache.php');
332 341
 			if(!empty($GLOBALS['sugar_config']['use_sprites']) && sugar_is_file($cachedfile)) {
@@ -378,13 +387,14 @@  discard block
 block discarded – undo
378 387
         // clear out the cache on destroy if we are asked to
379 388
         if ( $this->_clearCacheOnDestroy ) {
380 389
 
381
-            if (is_file("$cachedir/pathCache.php"))
382
-                unlink("$cachedir/pathCache.php");
383
-			if (is_file("$cachedir/spriteCache.php"))
384
-				unlink("$cachedir/spriteCache.php");
390
+            if (is_file("$cachedir/pathCache.php")) {
391
+                            unlink("$cachedir/pathCache.php");
392
+            }
393
+			if (is_file("$cachedir/spriteCache.php")) {
394
+							unlink("$cachedir/spriteCache.php");
395
+			}
385 396
 
386
-        }
387
-        elseif ( !inDeveloperMode() ) {
397
+        } elseif ( !inDeveloperMode() ) {
388 398
             // only update the caches if they have been changed in this request
389 399
             if ( count($this->_jsCache) != $this->_initialCacheSize['jsCache']
390 400
                     || count($this->_cssCache) != $this->_initialCacheSize['cssCache']
@@ -433,8 +443,9 @@  discard block
 block discarded – undo
433 443
         $key
434 444
         )
435 445
     {
436
-        if ( isset($this->$key) )
437
-            return $this->$key;
446
+        if ( isset($this->$key) ) {
447
+                    return $this->$key;
448
+        }
438 449
     }
439 450
 
440 451
     public function __isset($key){
@@ -607,38 +618,44 @@  discard block
 block discarded – undo
607 618
 		if(!empty($GLOBALS['sugar_config']['use_sprites']) && $GLOBALS['sugar_config']['use_sprites']) {
608 619
 
609 620
 			// system wide sprites
610
-			if(file_exists("cache/sprites/default/sprites.css"))
611
-				$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/default/sprites.css').'" />';
621
+			if(file_exists("cache/sprites/default/sprites.css")) {
622
+							$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/default/sprites.css').'" />';
623
+			}
612 624
 
613 625
 			// theme specific sprites
614
-			if(file_exists("cache/sprites/{$this->dirName}/sprites.css"))
615
-				$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/'.$this->dirName.'/sprites.css').'" />';
626
+			if(file_exists("cache/sprites/{$this->dirName}/sprites.css")) {
627
+							$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/'.$this->dirName.'/sprites.css').'" />';
628
+			}
616 629
 
617 630
 			// parent sprites
618 631
 			if($this->parentTheme && $parent = SugarThemeRegistry::get($this->parentTheme)) {
619
-				if(file_exists("cache/sprites/{$parent->dirName}/sprites.css"))
620
-					$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/'.$parent->dirName.'/sprites.css').'" />';
632
+				if(file_exists("cache/sprites/{$parent->dirName}/sprites.css")) {
633
+									$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/'.$parent->dirName.'/sprites.css').'" />';
634
+				}
621 635
 			}
622 636
 
623 637
 			// repeatable sprites
624
-			if(file_exists("cache/sprites/Repeatable/sprites.css"))
625
-				$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/Repeatable/sprites.css').'" />';
638
+			if(file_exists("cache/sprites/Repeatable/sprites.css")) {
639
+							$html .= '<link rel="stylesheet" type="text/css" href="'.getJSPath('cache/sprites/Repeatable/sprites.css').'" />';
640
+			}
626 641
 		}
627 642
 
628 643
         // for BC during upgrade
629 644
         if ( !empty($this->colors) ) {
630
-            if ( isset($_SESSION['authenticated_user_theme_color']) && in_array($_SESSION['authenticated_user_theme_color'], $this->colors))
631
-                $color = $_SESSION['authenticated_user_theme_color'];
632
-            else
633
-                $color = $this->colors[0];
645
+            if ( isset($_SESSION['authenticated_user_theme_color']) && in_array($_SESSION['authenticated_user_theme_color'], $this->colors)) {
646
+                            $color = $_SESSION['authenticated_user_theme_color'];
647
+            } else {
648
+                            $color = $this->colors[0];
649
+            }
634 650
             $html .= '<link rel="stylesheet" type="text/css" href="'.$this->getCSSURL('colors.'.$color.'.css').'" id="current_color_style" />';
635 651
         }
636 652
 
637 653
         if ( !empty($this->fonts) ) {
638
-            if ( isset($_SESSION['authenticated_user_theme_font']) && in_array($_SESSION['authenticated_user_theme_font'], $this->fonts))
639
-                $font = $_SESSION['authenticated_user_theme_font'];
640
-            else
641
-                $font = $this->fonts[0];
654
+            if ( isset($_SESSION['authenticated_user_theme_font']) && in_array($_SESSION['authenticated_user_theme_font'], $this->fonts)) {
655
+                            $font = $_SESSION['authenticated_user_theme_font'];
656
+            } else {
657
+                            $font = $this->fonts[0];
658
+            }
642 659
             $html .= '<link rel="stylesheet" type="text/css" href="'.$this->getCSSURL('fonts.'.$font.'.css').'" id="current_font_style" />';
643 660
         }
644 661
 
@@ -669,23 +686,24 @@  discard block
 block discarded – undo
669 686
         $templateName
670 687
         )
671 688
     {
672
-        if ( isset($this->_templateCache[$templateName]) )
673
-            return $this->_templateCache[$templateName];
689
+        if ( isset($this->_templateCache[$templateName]) ) {
690
+                    return $this->_templateCache[$templateName];
691
+        }
674 692
 
675 693
         $templatePath = '';
676
-        if (sugar_is_file('custom/'.$this->getTemplatePath().'/'.$templateName))
677
-            $templatePath = 'custom/'.$this->getTemplatePath().'/'.$templateName;
678
-        elseif (sugar_is_file($this->getTemplatePath().'/'.$templateName))
679
-            $templatePath = $this->getTemplatePath().'/'.$templateName;
680
-        elseif (isset($this->parentTheme)
694
+        if (sugar_is_file('custom/'.$this->getTemplatePath().'/'.$templateName)) {
695
+                    $templatePath = 'custom/'.$this->getTemplatePath().'/'.$templateName;
696
+        } elseif (sugar_is_file($this->getTemplatePath().'/'.$templateName)) {
697
+                    $templatePath = $this->getTemplatePath().'/'.$templateName;
698
+        } elseif (isset($this->parentTheme)
681 699
                 && SugarThemeRegistry::get($this->parentTheme) instanceOf SugarTheme
682
-                && ($filename = SugarThemeRegistry::get($this->parentTheme)->getTemplate($templateName)) != '')
683
-            $templatePath = $filename;
684
-        elseif (sugar_is_file('custom/'.$this->getDefaultTemplatePath().'/'.$templateName))
685
-            $templatePath = 'custom/'.$this->getDefaultTemplatePath().'/'.$templateName;
686
-        elseif (sugar_is_file($this->getDefaultTemplatePath().'/'.$templateName))
687
-            $templatePath = $this->getDefaultTemplatePath().'/'.$templateName;
688
-        else {
700
+                && ($filename = SugarThemeRegistry::get($this->parentTheme)->getTemplate($templateName)) != '') {
701
+                    $templatePath = $filename;
702
+        } elseif (sugar_is_file('custom/'.$this->getDefaultTemplatePath().'/'.$templateName)) {
703
+                    $templatePath = 'custom/'.$this->getDefaultTemplatePath().'/'.$templateName;
704
+        } elseif (sugar_is_file($this->getDefaultTemplatePath().'/'.$templateName)) {
705
+                    $templatePath = $this->getDefaultTemplatePath().'/'.$templateName;
706
+        } else {
689 707
             $GLOBALS['log']->warn("Template $templateName not found");
690 708
             return false;
691 709
         }
@@ -721,15 +739,17 @@  discard block
 block discarded – undo
721 739
 		// trap deprecated use of image extension
722 740
 		if(is_null($ext)) {
723 741
 			$imageNameExp = explode('.',$imageName);
724
-			if(count($imageNameExp) == 1)
725
-				$imageName .= '.gif';
742
+			if(count($imageNameExp) == 1) {
743
+							$imageName .= '.gif';
744
+			}
726 745
 		} else {
727 746
 			$imageName .= $ext;
728 747
 		}
729 748
 
730 749
 		// trap alt attributes in other_attributes
731
-		if(preg_match('/alt=["\']([^\'"]+)["\']/i', $other_attributes))
732
-			$GLOBALS['log']->debug("Sprites: alt attribute detected for $imageName");
750
+		if(preg_match('/alt=["\']([^\'"]+)["\']/i', $other_attributes)) {
751
+					$GLOBALS['log']->debug("Sprites: alt attribute detected for $imageName");
752
+		}
733 753
 		// sprite handler, makes use of own caching mechanism
734 754
 		if(!empty($GLOBALS['sugar_config']['use_sprites']) && $GLOBALS['sugar_config']['use_sprites']) {
735 755
 			// get sprite metadata
@@ -751,8 +771,9 @@  discard block
 block discarded – undo
751 771
 		// img caching
752 772
 		if(empty($cached_results[$imageName])) {
753 773
 			$imageURL = $this->getImageURL($imageName,false);
754
-			if ( empty($imageURL) )
755
-				return false;
774
+			if ( empty($imageURL) ) {
775
+							return false;
776
+			}
756 777
             if(strpos($imageURL, '.svg', strlen($imageURL)-4)){
757 778
                 $cached_results[$imageName] = file_get_contents($imageURL);
758 779
             } else {
@@ -779,8 +800,9 @@  discard block
 block discarded – undo
779 800
 	public function getSpriteMeta($imageName) {
780 801
 
781 802
 		// return from cache
782
-	    if(isset($this->_spriteCache[$imageName]))
783
-			return $this->_spriteCache[$imageName];
803
+	    if(isset($this->_spriteCache[$imageName])) {
804
+	    			return $this->_spriteCache[$imageName];
805
+	    }
784 806
 
785 807
 			// sprite keys are base on imageURL
786 808
 		$imageURL = $this->getImageURL($imageName,false);
@@ -832,8 +854,9 @@  discard block
 block discarded – undo
832 854
 			$attr .= ' class="spr_'.$class.'"';
833 855
 		}
834 856
 
835
-		if($title)
836
-			$attr .= ' title="'.$title.'"';
857
+		if($title) {
858
+					$attr .= ' title="'.$title.'"';
859
+		}
837 860
 
838 861
 		// use </span> instead of /> to prevent weird UI results
839 862
 		$GLOBALS['log']->debug("Sprites: generated sprite -> $attr");
@@ -887,35 +910,37 @@  discard block
 block discarded – undo
887 910
         $addJSPath = true
888 911
         ){
889 912
         if ( isset($this->_imageCache[$imageName]) ) {
890
-            if ( $addJSPath )
891
-                return getJSPath($this->_imageCache[$imageName]);
892
-            else
893
-                return $this->_imageCache[$imageName];
913
+            if ( $addJSPath ) {
914
+                            return getJSPath($this->_imageCache[$imageName]);
915
+            } else {
916
+                            return $this->_imageCache[$imageName];
917
+            }
894 918
         }
895 919
         $imagePath = '';
896
-        if (($filename = $this->_getImageFileName('custom/'.$this->getImagePath().'/'.$imageName)) != '')
897
-            $imagePath = $filename;
898
-        elseif (($filename = $this->_getImageFileName($this->getImagePath().'/'.$imageName)) != '')
899
-            $imagePath = $filename;
900
-        elseif (isset($this->parentTheme)
920
+        if (($filename = $this->_getImageFileName('custom/'.$this->getImagePath().'/'.$imageName)) != '') {
921
+                    $imagePath = $filename;
922
+        } elseif (($filename = $this->_getImageFileName($this->getImagePath().'/'.$imageName)) != '') {
923
+                    $imagePath = $filename;
924
+        } elseif (isset($this->parentTheme)
901 925
                 && SugarThemeRegistry::get($this->parentTheme) instanceOf SugarTheme
902
-                && ($filename = SugarThemeRegistry::get($this->parentTheme)->getImageURL($imageName,false)) != '')
903
-            $imagePath = $filename;
904
-        elseif (($filename = $this->_getImageFileName('custom/'.$this->getDefaultImagePath().'/'.$imageName)) != '')
905
-            $imagePath = $filename;
906
-        elseif (($filename = $this->_getImageFileName($this->getDefaultImagePath().'/'.$imageName)) != '')
907
-            $imagePath = $filename;
908
-		elseif (($filename = $this->_getImageFileName('include/images/'.$imageName)) != '')
909
-			$imagePath = $filename;
910
-        else {
926
+                && ($filename = SugarThemeRegistry::get($this->parentTheme)->getImageURL($imageName,false)) != '') {
927
+                    $imagePath = $filename;
928
+        } elseif (($filename = $this->_getImageFileName('custom/'.$this->getDefaultImagePath().'/'.$imageName)) != '') {
929
+                    $imagePath = $filename;
930
+        } elseif (($filename = $this->_getImageFileName($this->getDefaultImagePath().'/'.$imageName)) != '') {
931
+                    $imagePath = $filename;
932
+        } elseif (($filename = $this->_getImageFileName('include/images/'.$imageName)) != '') {
933
+					$imagePath = $filename;
934
+		} else {
911 935
             $GLOBALS['log']->warn("Image $imageName not found");
912 936
             return false;
913 937
         }
914 938
 
915 939
         $this->_imageCache[$imageName] = $imagePath;
916 940
 
917
-        if ( $addJSPath )
918
-            return getJSPath($imagePath);
941
+        if ( $addJSPath ) {
942
+                    return getJSPath($imagePath);
943
+        }
919 944
 
920 945
         return $imagePath;
921 946
     }
@@ -931,14 +956,16 @@  discard block
 block discarded – undo
931 956
         )
932 957
     {
933 958
         // return now if the extension matches that of which we are looking for
934
-        if ( sugar_is_file($imageName) )
935
-            return $imageName;
959
+        if ( sugar_is_file($imageName) ) {
960
+                    return $imageName;
961
+        }
936 962
         $pathParts = pathinfo($imageName);
937
-        foreach ( $this->imageExtensions as $extension )
938
-            if ( isset($pathParts['extension']) )
963
+        foreach ( $this->imageExtensions as $extension ) {
964
+                    if ( isset($pathParts['extension']) )
939 965
                 if ( ( $extension != $pathParts['extension'] )
940 966
                         && sugar_is_file($pathParts['dirname'].'/'.$pathParts['filename'].'.'.$extension) )
941 967
                     return $pathParts['dirname'].'/'.$pathParts['filename'].'.'.$extension;
968
+        }
942 969
 
943 970
         return '';
944 971
     }
@@ -954,10 +981,11 @@  discard block
 block discarded – undo
954 981
     public function getCSSURL($cssFileName, $returnURL = true)
955 982
     {
956 983
         if ( isset($this->_cssCache[$cssFileName]) && sugar_is_file(sugar_cached($this->_cssCache[$cssFileName])) ) {
957
-            if ( $returnURL )
958
-                return getJSPath("cache/".$this->_cssCache[$cssFileName]);
959
-            else
960
-                return sugar_cached($this->_cssCache[$cssFileName]);
984
+            if ( $returnURL ) {
985
+                            return getJSPath("cache/".$this->_cssCache[$cssFileName]);
986
+            } else {
987
+                            return sugar_cached($this->_cssCache[$cssFileName]);
988
+            }
961 989
         }
962 990
 
963 991
         $cssFileContents = '';
@@ -965,13 +993,15 @@  discard block
 block discarded – undo
965 993
         $fullFileName = $this->getCSSPath().'/'.$cssFileName;
966 994
         if (isset($this->parentTheme)
967 995
                 && SugarThemeRegistry::get($this->parentTheme) instanceOf SugarTheme
968
-                && ($filename = SugarThemeRegistry::get($this->parentTheme)->getCSSURL($cssFileName,false)) != '')
969
-            $cssFileContents .= file_get_contents($filename);
970
-        else {
971
-            if (sugar_is_file($defaultFileName))
972
-                $cssFileContents .= file_get_contents($defaultFileName);
973
-            if (sugar_is_file('custom/'.$defaultFileName))
974
-                $cssFileContents .= file_get_contents('custom/'.$defaultFileName);
996
+                && ($filename = SugarThemeRegistry::get($this->parentTheme)->getCSSURL($cssFileName,false)) != '') {
997
+                    $cssFileContents .= file_get_contents($filename);
998
+        } else {
999
+            if (sugar_is_file($defaultFileName)) {
1000
+                            $cssFileContents .= file_get_contents($defaultFileName);
1001
+            }
1002
+            if (sugar_is_file('custom/'.$defaultFileName)) {
1003
+                            $cssFileContents .= file_get_contents('custom/'.$defaultFileName);
1004
+            }
975 1005
         }
976 1006
         if (sugar_is_file($fullFileName)) {
977 1007
             $cssFileContents .= file_get_contents($fullFileName);
@@ -995,10 +1025,11 @@  discard block
 block discarded – undo
995 1025
         // if this is the style.css file, prepend the base.css and calendar-win2k-cold-1.css
996 1026
         // files before the theme styles
997 1027
         if ( $cssFileName == 'style.css' && !isset($this->parentTheme) ) {
998
-            if ( inDeveloperMode() )
999
-                $cssFileContents = file_get_contents('include/javascript/yui/build/base/base.css') . $cssFileContents;
1000
-            else
1001
-                $cssFileContents = file_get_contents('include/javascript/yui/build/base/base-min.css') . $cssFileContents;
1028
+            if ( inDeveloperMode() ) {
1029
+                            $cssFileContents = file_get_contents('include/javascript/yui/build/base/base.css') . $cssFileContents;
1030
+            } else {
1031
+                            $cssFileContents = file_get_contents('include/javascript/yui/build/base/base-min.css') . $cssFileContents;
1032
+            }
1002 1033
         }
1003 1034
 
1004 1035
         // minify the css
@@ -1011,8 +1042,9 @@  discard block
 block discarded – undo
1011 1042
 
1012 1043
         $this->_cssCache[$cssFileName] = $fullFileName;
1013 1044
 
1014
-        if ( $returnURL )
1015
-            return getJSPath("cache/".$fullFileName);
1045
+        if ( $returnURL ) {
1046
+                    return getJSPath("cache/".$fullFileName);
1047
+        }
1016 1048
 
1017 1049
         return sugar_cached($fullFileName);
1018 1050
     }
@@ -1028,10 +1060,11 @@  discard block
 block discarded – undo
1028 1060
     public function getJSURL($jsFileName, $returnURL = true)
1029 1061
     {
1030 1062
         if ( isset($this->_jsCache[$jsFileName]) && sugar_is_file(sugar_cached($this->_jsCache[$jsFileName])) ) {
1031
-            if ( $returnURL )
1032
-                return getJSPath("cache/".$this->_jsCache[$jsFileName]);
1033
-            else
1034
-                return sugar_cached($this->_jsCache[$jsFileName]);
1063
+            if ( $returnURL ) {
1064
+                            return getJSPath("cache/".$this->_jsCache[$jsFileName]);
1065
+            } else {
1066
+                            return sugar_cached($this->_jsCache[$jsFileName]);
1067
+            }
1035 1068
         }
1036 1069
 
1037 1070
         $jsFileContents = '';
@@ -1042,15 +1075,19 @@  discard block
 block discarded – undo
1042 1075
                 && ($filename = SugarThemeRegistry::get($this->parentTheme)->getJSURL($jsFileName,false)) != ''    && !in_array($jsFileName,$this->ignoreParentFiles)) {
1043 1076
            $jsFileContents .= file_get_contents($filename);
1044 1077
        } else {
1045
-            if (sugar_is_file($defaultFileName))
1046
-                $jsFileContents .= file_get_contents($defaultFileName);
1047
-            if (sugar_is_file('custom/'.$defaultFileName))
1048
-                $jsFileContents .= file_get_contents('custom/'.$defaultFileName);
1078
+            if (sugar_is_file($defaultFileName)) {
1079
+                            $jsFileContents .= file_get_contents($defaultFileName);
1080
+            }
1081
+            if (sugar_is_file('custom/'.$defaultFileName)) {
1082
+                            $jsFileContents .= file_get_contents('custom/'.$defaultFileName);
1083
+            }
1084
+        }
1085
+        if (sugar_is_file($fullFileName)) {
1086
+                    $jsFileContents .= file_get_contents($fullFileName);
1087
+        }
1088
+        if (sugar_is_file('custom/'.$fullFileName)) {
1089
+                    $jsFileContents .= file_get_contents('custom/'.$fullFileName);
1049 1090
         }
1050
-        if (sugar_is_file($fullFileName))
1051
-            $jsFileContents .= file_get_contents($fullFileName);
1052
-        if (sugar_is_file('custom/'.$fullFileName))
1053
-            $jsFileContents .= file_get_contents('custom/'.$fullFileName);
1054 1091
         if (empty($jsFileContents)) {
1055 1092
             $GLOBALS['log']->warn("Javascript File $jsFileName not found");
1056 1093
             return false;
@@ -1071,8 +1108,9 @@  discard block
 block discarded – undo
1071 1108
 
1072 1109
         $this->_jsCache[$jsFileName] = $fullFileName;
1073 1110
 
1074
-        if ( $returnURL )
1075
-            return getJSPath("cache/".$fullFileName);
1111
+        if ( $returnURL ) {
1112
+                    return getJSPath("cache/".$fullFileName);
1113
+        }
1076 1114
 
1077 1115
         return sugar_cached($fullFileName);
1078 1116
     }
@@ -1097,7 +1135,9 @@  discard block
 block discarded – undo
1097 1135
         $imageArray = array();
1098 1136
         foreach ( $pathsToSearch as $path )
1099 1137
         {
1100
-            if (!sugar_is_dir($path)) $path = "custom/$path";
1138
+            if (!sugar_is_dir($path)) {
1139
+                $path = "custom/$path";
1140
+            }
1101 1141
             if (sugar_is_dir($path) && is_readable($path) && $dir = opendir($path)) {
1102 1142
                 while (($file = readdir($dir)) !== false) {
1103 1143
                     if ($file == ".."
@@ -1105,10 +1145,12 @@  discard block
 block discarded – undo
1105 1145
                             || $file == ".svn"
1106 1146
                             || $file == "CVS"
1107 1147
                             || $file == "Attic"
1108
-                            )
1109
-                        continue;
1110
-                    if ( !isset($imageArray[$file]) )
1111
-                        $imageArray[$file] = $this->getImageURL($file,false);
1148
+                            ) {
1149
+                                            continue;
1150
+                    }
1151
+                    if ( !isset($imageArray[$file]) ) {
1152
+                                            $imageArray[$file] = $this->getImageURL($file,false);
1153
+                    }
1112 1154
                 }
1113 1155
                 closedir($dir);
1114 1156
             }
@@ -1189,8 +1231,9 @@  discard block
 block discarded – undo
1189 1231
         }
1190 1232
 
1191 1233
         // Assume theme is designed for 5.5.x if not specified otherwise
1192
-        if ( !isset($themedef['version']) )
1193
-            $themedef['version']['regex_matches'] = array('5\.5\.*');
1234
+        if ( !isset($themedef['version']) ) {
1235
+                    $themedef['version']['regex_matches'] = array('5\.5\.*');
1236
+        }
1194 1237
 
1195 1238
         // Check to see if theme is valid for this version of Sugar; return false if not
1196 1239
         $version_ok = false;
@@ -1210,8 +1253,9 @@  discard block
 block discarded – undo
1210 1253
                 }
1211 1254
             }
1212 1255
         }
1213
-        if ( !$version_ok )
1214
-            return false;
1256
+        if ( !$version_ok ) {
1257
+                    return false;
1258
+        }
1215 1259
 
1216 1260
         $theme = new SugarTheme($themedef);
1217 1261
         self::$_themes[$theme->dirName] = $theme;
@@ -1226,8 +1270,9 @@  discard block
 block discarded – undo
1226 1270
         $themeName
1227 1271
         )
1228 1272
     {
1229
-        if ( self::exists($themeName) )
1230
-            unset(self::$_themes[$themeName]);
1273
+        if ( self::exists($themeName) ) {
1274
+                    unset(self::$_themes[$themeName]);
1275
+        }
1231 1276
     }
1232 1277
 
1233 1278
     /**
@@ -1239,8 +1284,9 @@  discard block
 block discarded – undo
1239 1284
         $themeName
1240 1285
         )
1241 1286
     {
1242
-        if ( isset(self::$_themes[$themeName]) )
1243
-            return self::$_themes[$themeName];
1287
+        if ( isset(self::$_themes[$themeName]) ) {
1288
+                    return self::$_themes[$themeName];
1289
+        }
1244 1290
     }
1245 1291
 
1246 1292
     /**
@@ -1250,8 +1296,9 @@  discard block
 block discarded – undo
1250 1296
      */
1251 1297
     public static function current()
1252 1298
     {
1253
-        if ( !isset(self::$_currentTheme) )
1254
-            self::buildRegistry();
1299
+        if ( !isset(self::$_currentTheme) ) {
1300
+                    self::buildRegistry();
1301
+        }
1255 1302
 
1256 1303
         return self::$_themes[self::$_currentTheme];
1257 1304
     }
@@ -1263,8 +1310,9 @@  discard block
 block discarded – undo
1263 1310
      */
1264 1311
     public static function getDefault()
1265 1312
     {
1266
-        if ( !isset(self::$_currentTheme) )
1267
-            self::buildRegistry();
1313
+        if ( !isset(self::$_currentTheme) ) {
1314
+                    self::buildRegistry();
1315
+        }
1268 1316
 
1269 1317
         if ( isset($GLOBALS['sugar_config']['default_theme']) && self::exists($GLOBALS['sugar_config']['default_theme']) ) {
1270 1318
             return self::get($GLOBALS['sugar_config']['default_theme']);
@@ -1295,8 +1343,9 @@  discard block
 block discarded – undo
1295 1343
         $themeName
1296 1344
         )
1297 1345
     {
1298
-        if ( !self::exists($themeName) )
1299
-            return false;
1346
+        if ( !self::exists($themeName) ) {
1347
+                    return false;
1348
+        }
1300 1349
 
1301 1350
         self::$_currentTheme = $themeName;
1302 1351
 
@@ -1333,8 +1382,9 @@  discard block
 block discarded – undo
1333 1382
                             || $file == "default"
1334 1383
                             || !sugar_is_dir("./$dirPath".$file)
1335 1384
                             || !sugar_is_file("./{$dirPath}{$file}/themedef.php")
1336
-                            )
1337
-                        continue;
1385
+                            ) {
1386
+                                            continue;
1387
+                    }
1338 1388
                     $themedef = array();
1339 1389
                     require("./{$dirPath}{$file}/themedef.php");
1340 1390
                     $themedef = array_merge($themedef,$themedefDefault);
@@ -1343,9 +1393,10 @@  discard block
 block discarded – undo
1343 1393
                     // if so, then it will override the current one
1344 1394
                     if ( self::exists($themedef['dirName']) ) {
1345 1395
                         $existingTheme = self::get($themedef['dirName']);
1346
-                        foreach ( SugarTheme::getThemeDefFields() as $field )
1347
-                            if ( !isset($themedef[$field]) )
1396
+                        foreach ( SugarTheme::getThemeDefFields() as $field ) {
1397
+                                                    if ( !isset($themedef[$field]) )
1348 1398
                                 $themedef[$field] = $existingTheme->$field;
1399
+                        }
1349 1400
                         self::remove($themedef['dirName']);
1350 1401
                     }
1351 1402
                     if ( isset($themedef['name']) ) {
@@ -1400,12 +1451,14 @@  discard block
 block discarded – undo
1400 1451
     {
1401 1452
         $themelist = array();
1402 1453
         $disabledThemes = array();
1403
-        if ( isset($GLOBALS['sugar_config']['disabled_themes']) )
1404
-            $disabledThemes = explode(',',$GLOBALS['sugar_config']['disabled_themes']);
1454
+        if ( isset($GLOBALS['sugar_config']['disabled_themes']) ) {
1455
+                    $disabledThemes = explode(',',$GLOBALS['sugar_config']['disabled_themes']);
1456
+        }
1405 1457
 
1406 1458
         foreach ( self::$_themes as $themename => $themeobject ) {
1407
-            if ( in_array($themename,$disabledThemes) )
1408
-                continue;
1459
+            if ( in_array($themename,$disabledThemes) ) {
1460
+                            continue;
1461
+            }
1409 1462
             $themelist[$themeobject->dirName] = $themeobject->name;
1410 1463
         }
1411 1464
         asort($themelist, SORT_STRING);
@@ -1421,12 +1474,14 @@  discard block
 block discarded – undo
1421 1474
     {
1422 1475
         $themelist = array();
1423 1476
         $disabledThemes = array();
1424
-        if ( isset($GLOBALS['sugar_config']['disabled_themes']) )
1425
-            $disabledThemes = explode(',',$GLOBALS['sugar_config']['disabled_themes']);
1477
+        if ( isset($GLOBALS['sugar_config']['disabled_themes']) ) {
1478
+                    $disabledThemes = explode(',',$GLOBALS['sugar_config']['disabled_themes']);
1479
+        }
1426 1480
 
1427 1481
         foreach ( self::$_themes as $themename => $themeobject ) {
1428
-            if ( in_array($themename,$disabledThemes) )
1429
-                $themelist[$themeobject->dirName] = $themeobject->name;
1482
+            if ( in_array($themename,$disabledThemes) ) {
1483
+                            $themelist[$themeobject->dirName] = $themeobject->name;
1484
+            }
1430 1485
         }
1431 1486
 
1432 1487
         return $themelist;
@@ -1441,8 +1496,9 @@  discard block
 block discarded – undo
1441 1496
     {
1442 1497
         $themelist = array();
1443 1498
 
1444
-        foreach ( self::$_themes as $themename => $themeobject )
1445
-            $themelist[$themeobject->dirName] = $themeobject->name;
1499
+        foreach ( self::$_themes as $themename => $themeobject ) {
1500
+                    $themelist[$themeobject->dirName] = $themeobject->name;
1501
+        }
1446 1502
 
1447 1503
         return $themelist;
1448 1504
     }
@@ -1456,8 +1512,9 @@  discard block
 block discarded – undo
1456 1512
     {
1457 1513
         $themelist = array();
1458 1514
         $disabledThemes = array();
1459
-        if (isset($GLOBALS['sugar_config']['disabled_themes']))
1460
-            $disabledThemes = explode(',', $GLOBALS['sugar_config']['disabled_themes']);
1515
+        if (isset($GLOBALS['sugar_config']['disabled_themes'])) {
1516
+                    $disabledThemes = explode(',', $GLOBALS['sugar_config']['disabled_themes']);
1517
+        }
1461 1518
 
1462 1519
         foreach (self::$_themes as $themename => $themeobject) {
1463 1520
             $themearray['name'] = $themeobject->name;
@@ -1478,8 +1535,9 @@  discard block
 block discarded – undo
1478 1535
     {
1479 1536
         global $sugar_config;
1480 1537
 
1481
-        if ( !self::exists($themeName) )
1482
-            return false;
1538
+        if ( !self::exists($themeName) ) {
1539
+                    return false;
1540
+        }
1483 1541
 
1484 1542
         $config = array();
1485 1543
 
Please login to merge, or discard this patch.