Completed
Push — develop ( 7c1bda...edae1e )
by Adam
18:38 queued 03:14
created
modules/Administration/RebuildConfig.php 1 patch
Braces   +5 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.
@@ -56,8 +58,7 @@  discard block
 block discarded – undo
56 58
     $config_check = $mod_strings['MSG_CONFIG_FILE_READY_FOR_REBUILD'];
57 59
     $disable_config_rebuild = '';
58 60
     $config_file_ready = true;
59
-}
60
-else {
61
+} else {
61 62
     $config_check = $mod_strings['MSG_MAKE_CONFIG_FILE_WRITABLE'];
62 63
 }
63 64
 
@@ -70,8 +71,7 @@  discard block
 block discarded – undo
70 71
     if ( rebuildConfigFile($clean_config, $sugar_version) ) {
71 72
     	$config_check = $mod_strings['MSG_CONFIG_FILE_REBUILD_SUCCESS'];
72 73
         $disable_config_rebuild = 'disabled="disabled"';
73
-    }
74
-    else {
74
+    } else {
75 75
         $config_check = $mod_strings['MSG_CONFIG_FILE_REBUILD_FAILED'];
76 76
     }	
77 77
 
Please login to merge, or discard this patch.
modules/Administration/UpgradeWizard.php 1 patch
Braces   +6 added lines, -6 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.
@@ -66,8 +68,7 @@  discard block
 block discarded – undo
66 68
 	$uploaddLabel = $mod_strings['LBL_UW_UPLOAD_MODULE'];
67 69
 	$descItemsQueued = $mod_strings['LBL_UW_DESC_MODULES_QUEUED'];
68 70
 	$descItemsInstalled = $mod_strings['LBL_UW_DESC_MODULES_INSTALLED'];
69
-}
70
-else {
71
+} else {
71 72
 
72 73
 	$uploaddLabel = $mod_strings['LBL_UPLOAD_UPGRADE'];
73 74
 	$descItemsQueued = $mod_strings['DESC_FILES_QUEUED'];
@@ -209,8 +210,7 @@  discard block
 block discarded – undo
209 210
 
210 211
 if( $view == "module") {
211 212
 	print( getClassicModuleTitle($mod_strings['LBL_MODULE_NAME'], array($mod_strings['LBL_MODULE_LOADER_TITLE']), false) );
212
-}
213
-else {
213
+} else {
214 214
 	print( getClassicModuleTitle($mod_strings['LBL_MODULE_NAME'], array($mod_strings['LBL_MODULE_NAME'],$mod_strings['LBL_UPGRADE_WIZARD_TITLE']), false) );
215 215
 }
216 216
 
@@ -231,7 +231,7 @@  discard block
 block discarded – undo
231 231
 	$form .= '</table></form>';
232 232
 //rrs
233 233
 
234
-}else{
234
+} else{
235 235
     $form =<<<eoq
236 236
 <form name="the_form" enctype="multipart/form-data" action="{$form_action}" method="post"  >
237 237
 <table width="100%" border="0" cellspacing="0" cellpadding="0" class="edit view">
Please login to merge, or discard this patch.
modules/Administration/repairDatabase.php 1 patch
Braces   +9 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if (!defined('sugarEntry') || !sugarEntry)
2
+if (!defined('sugarEntry') || !sugarEntry) {
3 3
 	die('Not A Valid Entry Point');
4
+}
4 5
 /*********************************************************************************
5 6
  * SugarCRM Community Edition is a customer relationship management program developed by
6 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -70,8 +71,7 @@  discard block
 block discarded – undo
70 71
 		    $sql = str_replace('&#039;',"'", $_POST['sql']);
71 72
 		    //echo html_entity_decode($_POST['sql']);
72 73
 		    echo $sql;
73
-		}
74
-		elseif (isset ($_POST['raction']) && strtolower($_POST['raction']) == "execute") {
74
+		} elseif (isset ($_POST['raction']) && strtolower($_POST['raction']) == "execute") {
75 75
 			$sql = str_replace(
76 76
 				array(
77 77
 					"\n",
@@ -96,8 +96,9 @@  discard block
 block discarded – undo
96 96
 	} else {
97 97
 
98 98
 		if (!$export && empty ($_REQUEST['repair_silent'])) {
99
-			if ( empty($hideModuleMenu) )
100
-		        echo getClassicModuleTitle($mod_strings['LBL_REPAIR_DATABASE'], array($mod_strings['LBL_REPAIR_DATABASE']), true);
99
+			if ( empty($hideModuleMenu) ) {
100
+					        echo getClassicModuleTitle($mod_strings['LBL_REPAIR_DATABASE'], array($mod_strings['LBL_REPAIR_DATABASE']), true);
101
+			}
101 102
 			echo "<h1 id=\"rdloading\">{$mod_strings['LBL_REPAIR_DATABASE_PROCESSING']}</h1>";
102 103
 			ob_flush();
103 104
 		}
@@ -137,8 +138,9 @@  discard block
 block discarded – undo
137 138
 
138 139
 		foreach ($dictionary as $meta) {
139 140
 
140
-			if ( !isset($meta['table']) || isset($repairedTables[$meta['table']]))
141
-                continue;
141
+			if ( !isset($meta['table']) || isset($repairedTables[$meta['table']])) {
142
+			                continue;
143
+			}
142 144
             
143 145
             $tablename = $meta['table'];
144 146
 			$fielddefs = $meta['fields'];
Please login to merge, or discard this patch.
modules/Administration/UpgradeFields.php 1 patch
Braces   +5 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@  discard block
 block discarded – undo
1 1
 <?php
2
-if(!defined('sugarEntry') || !sugarEntry)
2
+if(!defined('sugarEntry') || !sugarEntry) {
3 3
 	die('Not A Valid Entry Point');
4
+}
4 5
 /*********************************************************************************
5 6
  * SugarCRM Community Edition is a customer relationship management program developed by
6 7
  * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc.
@@ -120,8 +121,9 @@  discard block
 block discarded – undo
120 121
 	echo sizeof($fields)." field(s) missing from $mod->table_name"."_cstm<br>";
121 122
 	foreach ($fields as $field) {
122 123
 		echo "Adding Column $field to $mod->table_name"."_cstm<br>";
123
-		if (!$simulate)
124
-			$mod->custom_fields->add_existing_custom_field($field);
124
+		if (!$simulate) {
125
+					$mod->custom_fields->add_existing_custom_field($field);
126
+		}
125 127
 	}
126 128
 
127 129
 }
Please login to merge, or discard this patch.
modules/Administration/callJSRepair.php 1 patch
Braces   +6 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.
@@ -60,7 +62,7 @@  discard block
 block discarded – undo
60 62
             $_REQUEST['js_rebuild_concat'] = 'rebuild';
61 63
             require_once('jssource/minify.php');
62 64
          
63
-        }else{
65
+        } else{
64 66
             $_REQUEST['root_directory'] = getcwd();
65 67
             require_once('jssource/minify.php');
66 68
         
@@ -68,13 +70,13 @@  discard block
 block discarded – undo
68 70
                 //should replace compressed JS with source js
69 71
                 reverseScripts("$from/jssource/src_files","$from");    
70 72
     
71
-            }elseif($_REQUEST['js_admin_repair'] == 'mini'){
73
+            } elseif($_REQUEST['js_admin_repair'] == 'mini'){
72 74
                 //should replace compressed JS with minified version of source js
73 75
                 reverseScripts("$from/jssource/src_files","$from");
74 76
                 BackUpAndCompressScriptFiles("$from","",false);
75 77
                 ConcatenateFiles("$from");
76 78
     
77
-            }elseif($_REQUEST['js_admin_repair'] == 'repair'){
79
+            } elseif($_REQUEST['js_admin_repair'] == 'repair'){
78 80
              //should compress existing javascript (including changes done) without overwriting original source files
79 81
                 BackUpAndCompressScriptFiles("$from","",false);
80 82
                 ConcatenateFiles("$from");        
Please login to merge, or discard this patch.
modules/Administration/RebuildDashlets.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.
@@ -50,9 +52,10 @@  discard block
 block discarded – undo
50 52
 
51 53
     $dc = new DashletCacheBuilder();
52 54
     $dc->buildCache();
53
-   if( !$silent ) echo '<br><br><br><br>' . $mod_strings['LBL_REBUILD_DASHLETS_DESC_SUCCESS'];
54
-}
55
-else{
55
+   if( !$silent ) {
56
+       echo '<br><br><br><br>' . $mod_strings['LBL_REBUILD_DASHLETS_DESC_SUCCESS'];
57
+   }
58
+   } else{
56 59
 	sugar_die($GLOBALS['app_strings']['ERR_NOT_ADMIN']);
57 60
 }
58 61
 ?>
59 62
\ No newline at end of file
Please login to merge, or discard this patch.
modules/Administration/UpgradeWizardCommon.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.
@@ -54,8 +56,7 @@  discard block
 block discarded – undo
54 56
     if( $view != "default" && $view != "module" ){
55 57
         die($mod_strings['ERR_UW_INVALID_VIEW']);
56 58
     }
57
-}
58
-else{
59
+} else{
59 60
     die($mod_strings['ERR_UW_NO_VIEW']);
60 61
 }
61 62
 $form_action = "index.php?module=Administration&view=" . $view . "&action=UpgradeWizard";
Please login to merge, or discard this patch.
modules/Administration/updateTimezonePrefs.php 1 patch
Braces   +15 added lines, -11 removed lines patch added patch discarded remove patch
@@ -44,7 +44,9 @@  discard block
 block discarded – undo
44 44
 
45 45
 <table>
46 46
 <?php
47
-if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
47
+if(!defined('sugarEntry') || !sugarEntry) {
48
+    die('Not A Valid Entry Point');
49
+}
48 50
 $prompt_users = 'checked';
49 51
 if(isset($_POST['preview']) && !isset($_POST['prompt_users'])){
50 52
 	$prompt_users = '';
@@ -66,7 +68,9 @@  discard block
 block discarded – undo
66 68
 	}
67 69
 	
68 70
 		$string = "Preview";
69
-		if($execute)$string = "Updating";
71
+		if($execute) {
72
+		    $string = "Updating";
73
+		}
70 74
         echo "<tr><td> $string timezone preferences for user <b>{$row['user_name']}</b>...</td><td>";
71 75
 		
72 76
         
@@ -93,20 +97,20 @@  discard block
 block discarded – undo
93 97
 	                   	 	$setTo = $selectedZone;
94 98
 	                   	 	if(empty($prompt_users)){
95 99
 	                   			$newprefs['ut']=1;
96
-	                   	 	}else{
100
+	                   	 	} else{
97 101
 	                   	 		$newprefs['ut']=0;
98 102
 	                   	 	}
99
-	                	}else{
103
+	                	} else{
100 104
 	                		$newprefs['timezone'] = $serverTimeZone;   
101 105
 	                   	 	$newprefs['timez']  = $val;
102 106
 	                   	 	$setTo = $serverTimeZone;
103 107
 	                   	 	if(empty($prompt_users)){
104 108
 	                   			$newprefs['ut']=1;
105
-	                   	 	}else{
109
+	                   	 	} else{
106 110
 	                   	 		$newprefs['ut']=0;
107 111
 	                   	 	}
108 112
 	                	}
109
-	                }else{
113
+	                } else{
110 114
 	                	$newprefs[$key] = $val;
111 115
 	                	if(!empty($prefs['timezone'])){
112 116
 	                		$alreadySet = 'Previously Set - '. $prefs['timezone'];	
@@ -114,7 +118,7 @@  discard block
 block discarded – undo
114 118
 	                }
115 119
 	                
116 120
 	         
117
-	                }else{
121
+	                } else{
118 122
 	                	$newprefs[$key] = $val;
119 123
 	                }
120 124
 	        }
@@ -125,10 +129,10 @@  discard block
 block discarded – undo
125 129
 	        }
126 130
 		if(!empty($setTo)){
127 131
 			echo $setTo;
128
-		}else{
132
+		} else{
129 133
 			if(!empty($alreadySet)){
130 134
 				echo $alreadySet;
131
-			}else{
135
+			} else{
132 136
 				echo $serverTimeZone;
133 137
 				$prefs['timezone'] = $serverTimeZone;
134 138
 			}
@@ -140,7 +144,7 @@  discard block
 block discarded – undo
140 144
 			if(isset($_POST[$row['id'].'adjust'])){
141 145
 				echo  $adjustment;
142 146
 			}
143
-		}else{
147
+		} else{
144 148
 			echo "<select name='{$row['id']}adjust'>";
145 149
 			
146 150
 			echo get_select_options_with_id(array('-1'=>'-1', 'none'=>'0', '1'=>'+1'), $adjustment.'');
@@ -165,7 +169,7 @@  discard block
 block discarded – undo
165 169
 if($execute){
166 170
 	echo "<br>All timezone preferences updated!<br><br>";
167 171
 	
168
-}else{
172
+} else{
169 173
 	echo "Prompt users on login to confirm:<input type='checkbox' name='prompt_users' value='1' $prompt_users><br>";
170 174
 	echo "<input class='button' type='submit' name='execute' value='Execute'>&nbsp; <input class='button' type='submit' name='preview' value='Preview'>";
171 175
 	
Please login to merge, or discard this patch.
modules/InboundEmail/AOPInboundEmail.php 1 patch
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
             }
74 74
             if($email->description_html) {
75 75
                 $c->description = $this->processImageLinks(SugarCleaner::cleanHtml($email->description_html),$noteIds);
76
-            }else{
76
+            } else{
77 77
                 $c->description = $email->description;
78 78
             }
79 79
             $c->assigned_user_id = $userId;
Please login to merge, or discard this patch.