Completed
Push — work-fleets ( 4d76fa...c97fe0 )
by SuperNova.WS
05:17
created
admin/ajax_maintenance.php 1 patch
Spacing   +29 added lines, -29 removed lines patch added patch discarded remove patch
@@ -2,9 +2,9 @@  discard block
 block discarded – undo
2 2
 
3 3
 define('IN_ADMIN', true);
4 4
 
5
-require('../includes/init.' . substr(strrchr(__FILE__, '.'), 1));
5
+require('../includes/init.'.substr(strrchr(__FILE__, '.'), 1));
6 6
 
7
-if($user['authlevel'] < 3)
7
+if ($user['authlevel'] < 3)
8 8
 {
9 9
   message(classLocale::$lang['sys_noalloaw'], classLocale::$lang['sys_noaccess']);
10 10
   die();
@@ -20,13 +20,13 @@  discard block
 block discarded – undo
20 20
 // [#] info_best_battles 1b0
21 21
 $best_reports = array();
22 22
 
23
-if(defined('MODULE_INFO_BEST_BATTLES_QUERY')) {
23
+if (defined('MODULE_INFO_BEST_BATTLES_QUERY')) {
24 24
   $query = db_ube_report_get_best_battles();
25
-  while($row = db_fetch($query)) {
25
+  while ($row = db_fetch($query)) {
26 26
     $best_reports[] = $row['ube_report_id'];
27 27
   }
28 28
 }
29
-$best_reports = !empty($best_reports) ? ' AND ube_report_id NOT IN (' . implode(',', $best_reports) . ')' : '';
29
+$best_reports = !empty($best_reports) ? ' AND ube_report_id NOT IN ('.implode(',', $best_reports).')' : '';
30 30
 
31 31
 
32 32
 $ques = array(
@@ -90,14 +90,14 @@  discard block
 block discarded – undo
90 90
   // Удаляем юниты без планет
91 91
   'DELETE un FROM {{unit}} AS un
92 92
     LEFT JOIN {{planets}} AS pl ON pl.id = un.unit_location_id
93
-  WHERE unit_location_type = ' . LOC_PLANET . ' AND pl.id IS NULL;',
93
+  WHERE unit_location_type = ' . LOC_PLANET.' AND pl.id IS NULL;',
94 94
   // Удаляем пустые юниты с 0 уровнем (кроме Капитана)
95
-  'DELETE FROM {{unit}} WHERE unit_location_type = ' . LOC_PLANET . ' AND unit_level = 0 AND unit_type <> ' . UNIT_CAPTAIN,
95
+  'DELETE FROM {{unit}} WHERE unit_location_type = '.LOC_PLANET.' AND unit_level = 0 AND unit_type <> '.UNIT_CAPTAIN,
96 96
   // Удаляем очереди на ничьих планетах
97 97
   'DELETE q FROM {{que}} AS q
98 98
     LEFT JOIN {{planets}} AS p ON p.id = q.que_planet_id
99 99
   WHERE
100
-    que_type IN (' . QUE_STRUCTURES . ', ' . QUE_HANGAR . ', ' . SUBQUE_FLEET . ', ' . SUBQUE_DEFENSE . ')
100
+    que_type IN (' . QUE_STRUCTURES.', '.QUE_HANGAR.', '.SUBQUE_FLEET.', '.SUBQUE_DEFENSE.')
101 101
     AND
102 102
     (p.id_owner = 0 OR p.id_owner IS NULL);',
103 103
 
@@ -112,12 +112,12 @@  discard block
 block discarded – undo
112 112
   // Удаляются сообщения, старше  4 недель, кроме личных и Альянсовских
113 113
   'DELETE FROM {{messages}} WHERE
114 114
     UNIX_TIMESTAMP() - message_time > 4*7 * 24 * 60 * 60 AND
115
-    message_type NOT IN (' . MSG_TYPE_PLAYER . ', ' . MSG_TYPE_ALLIANCE . ');',
115
+    message_type NOT IN (' . MSG_TYPE_PLAYER.', '.MSG_TYPE_ALLIANCE.');',
116 116
   // Удаляются сообщения у пользователей, которые неактивны больше 4 недель - кроме личных и Альянсовских
117 117
   'DELETE m FROM `{{users}}` AS u
118 118
   JOIN {{messages}} AS m ON m.message_owner = u.id
119 119
   WHERE
120
-    message_type NOT IN (' . MSG_TYPE_PLAYER . ', ' . MSG_TYPE_ALLIANCE . ') AND
120
+    message_type NOT IN (' . MSG_TYPE_PLAYER.', '.MSG_TYPE_ALLIANCE.') AND
121 121
     authlevel = 0 AND  user_as_ally IS NULL AND /* Не админы, Не Альянсы */
122 122
     UNIX_TIMESTAMP() - onlinetime > 4*7 *86400;',
123 123
 
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
       (log_dark_matter_timestamp, log_dark_matter_username, log_dark_matter_reason, log_dark_matter_amount,
138 138
       log_dark_matter_comment, log_dark_matter_page, log_dark_matter_sender)
139 139
     SELECT
140
-      '{$pack_until}', IF(u.username IS NULL, ldm.log_dark_matter_username, u.username), " . RPG_CUMULATIVE . ", sum(ldm.log_dark_matter_amount),
140
+      '{$pack_until}', IF(u.username IS NULL, ldm.log_dark_matter_username, u.username), ".RPG_CUMULATIVE.", sum(ldm.log_dark_matter_amount),
141 141
       'Баланс на {$pack_until}', 'admin/ajax_maintenance.php', ldm.log_dark_matter_sender
142 142
     FROM
143 143
       {{log_dark_matter}} AS ldm
@@ -155,22 +155,22 @@  discard block
 block discarded – undo
155 155
     "REPLACE INTO `{{log_users_online}}`
156 156
       (online_timestamp, online_count, online_aggregated)
157 157
     SELECT
158
-      FROM_UNIXTIME((UNIX_TIMESTAMP(online_timestamp) DIV " . PERIOD_MINUTE_10 . ") * (" . PERIOD_MINUTE_10 . ")), ceil(avg(online_count)), " . LOG_ONLIINE_AGGREGATE_PERIOD_MINUTE_10 . "
158
+      FROM_UNIXTIME((UNIX_TIMESTAMP(online_timestamp) DIV " . PERIOD_MINUTE_10.") * (".PERIOD_MINUTE_10.")), ceil(avg(online_count)), ".LOG_ONLIINE_AGGREGATE_PERIOD_MINUTE_10."
159 159
     FROM
160 160
       `{{log_users_online}}`
161 161
     WHERE
162
-      online_timestamp < '{$pack_until}' AND online_aggregated = " . LOG_ONLIINE_AGGREGATE_NONE . "
162
+      online_timestamp < '{$pack_until}' AND online_aggregated = ".LOG_ONLIINE_AGGREGATE_NONE."
163 163
     GROUP BY
164
-      (UNIX_TIMESTAMP(online_timestamp) DIV " . PERIOD_MINUTE_10 . ") * (" . PERIOD_MINUTE_10 . ");",
164
+      (UNIX_TIMESTAMP(online_timestamp) DIV " . PERIOD_MINUTE_10.") * (".PERIOD_MINUTE_10.");",
165 165
 
166
-    "DELETE FROM {{log_users_online}} WHERE online_timestamp < '{$pack_until}' AND online_aggregated = " . LOG_ONLIINE_AGGREGATE_NONE,
166
+    "DELETE FROM {{log_users_online}} WHERE online_timestamp < '{$pack_until}' AND online_aggregated = ".LOG_ONLIINE_AGGREGATE_NONE,
167 167
   ),
168 168
 
169 169
   // Удаляем старые записи из логов
170 170
   "DELETE FROM `{{logs}}` WHERE log_timestamp < '{$pack_until}';",
171 171
   // Удаляем записи о маинтенансе, апдейте и пересчете статистики более чем недельной давности - они нам уже не нужны
172 172
   'DELETE FROM `{{logs}}` WHERE
173
-    `log_code` IN (' . LOG_INFO_DB_CHANGE . ', ' . LOG_INFO_MAINTENANCE . ', ' . LOG_INFO_STAT_START . ', ' . LOG_INFO_STAT_PROCESS . ', ' . LOG_INFO_STAT_FINISH . ')
173
+    `log_code` IN (' . LOG_INFO_DB_CHANGE.', '.LOG_INFO_MAINTENANCE.', '.LOG_INFO_STAT_START.', '.LOG_INFO_STAT_PROCESS.', '.LOG_INFO_STAT_FINISH.')
174 174
     AND `log_timestamp` < DATE_SUB(NOW(),INTERVAL 7 DAY);',
175 175
 
176 176
 
@@ -186,16 +186,16 @@  discard block
 block discarded – undo
186 186
 
187 187
 function sn_maintenance_pack_user_list($user_list) {
188 188
   $user_list = explode(',', $user_list);
189
-  foreach($user_list as $key => $user_id) {
190
-    if(!ceil(floatval($user_id))) {
189
+  foreach ($user_list as $key => $user_id) {
190
+    if (!ceil(floatval($user_id))) {
191 191
       unset($user_list[$key]);
192 192
     }
193 193
   }
194 194
 
195 195
   $result = array();
196
-  if(!empty($user_list)) {
196
+  if (!empty($user_list)) {
197 197
     $query = db_user_list_get_by_id_array($user_list);
198
-    while($row = db_fetch($query)) {
198
+    while ($row = db_fetch($query)) {
199 199
       $result[] = $row['id'];
200 200
     }
201 201
   }
@@ -208,13 +208,13 @@  discard block
 block discarded – undo
208 208
 $old_server_status == GAME_DISABLE_NONE ? classSupernova::$config->db_saveItem('game_disable', GAME_DISABLE_MAINTENANCE) : false;
209 209
 sn_db_transaction_commit();
210 210
 
211
-foreach($ques as $que_transaction) {
211
+foreach ($ques as $que_transaction) {
212 212
   sn_db_transaction_start();
213 213
 
214 214
   !is_array($que_transaction) ? $que_transaction = array($que_transaction) : false;
215
-  foreach($que_transaction as $que) {
215
+  foreach ($que_transaction as $que) {
216 216
     set_time_limit(120);
217
-    if(is_callable($que)) {
217
+    if (is_callable($que)) {
218 218
       $QryResult = call_user_func($que);
219 219
     } else {
220 220
       $QryResult = doquery($que);
@@ -225,12 +225,12 @@  discard block
 block discarded – undo
225 225
     //$que = str_replace('}}', '', $que);
226 226
 
227 227
     $msg .=
228
-      '<li>' . htmlspecialchars($que) .
229
-        ' --- <span style="' . ($QryResult ? 'ok">OK' : 'error">FAILED!') . '</span> ' .
230
-      classSupernova::$db->db_affected_rows() . ' ' . classLocale::$lang['adm_records'] .
228
+      '<li>'.htmlspecialchars($que).
229
+        ' --- <span style="'.($QryResult ? 'ok">OK' : 'error">FAILED!').'</span> '.
230
+      classSupernova::$db->db_affected_rows().' '.classLocale::$lang['adm_records'].
231 231
       "</li>";
232 232
 
233
-    classSupernova::$debug->warning($que . ' --- ' . ($QryResult ? 'OK' : 'FAILED!') . ' ' . classSupernova::$db->db_affected_rows() . ' ' . classLocale::$lang['adm_records'], 'System maintenance', LOG_INFO_MAINTENANCE);
233
+    classSupernova::$debug->warning($que.' --- '.($QryResult ? 'OK' : 'FAILED!').' '.classSupernova::$db->db_affected_rows().' '.classLocale::$lang['adm_records'], 'System maintenance', LOG_INFO_MAINTENANCE);
234 234
   }
235 235
 
236 236
   sn_db_transaction_commit();
@@ -256,5 +256,5 @@  discard block
 block discarded – undo
256 256
 
257 257
 $adm_stat_title = classLocale::$lang['adm_stat_title'];
258 258
 $result = $result ? "<li>{$adm_stat_title} - {$result}</li>" : '';
259
-$result = '<div align="left"><ul>' . $msg . $result . '</ul></div>';
260
-echo json_encode($result . ' ' . $totaltime);
259
+$result = '<div align="left"><ul>'.$msg.$result.'</ul></div>';
260
+echo json_encode($result.' '.$totaltime);
Please login to merge, or discard this patch.
admin/adm_log_main.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -12,27 +12,27 @@  discard block
 block discarded – undo
12 12
 define('INSTALL', false);
13 13
 define('IN_ADMIN', true);
14 14
 
15
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
15
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
16 16
 
17
-if($user['authlevel'] < 3) {
17
+if ($user['authlevel'] < 3) {
18 18
   AdminMessage(classLocale::$lang['adm_err_denied']);
19 19
 }
20 20
 
21
-if($delete = sys_get_param_id('delete')) {
21
+if ($delete = sys_get_param_id('delete')) {
22 22
   db_log_delete_by_id($delete);
23
-} elseif(sys_get_param_str('delete_update_info')) {
23
+} elseif (sys_get_param_str('delete_update_info')) {
24 24
   db_log_delete_update_and_stat_calc();
25
-} elseif(sys_get_param_str('deleteall') == 'yes') {
25
+} elseif (sys_get_param_str('deleteall') == 'yes') {
26 26
 //  doquery("TRUNCATE TABLE `{{logs}}`");
27 27
 }
28 28
 
29
-if($detail = sys_get_param_id('detail')) {
29
+if ($detail = sys_get_param_id('detail')) {
30 30
   $template = gettemplate('admin/adm_log_main_detail', true);
31 31
 
32 32
   $errorInfo = db_log_get_by_id($detail);
33 33
   $error_dump = unserialize($errorInfo['log_dump']);
34
-  if(is_array($error_dump)) {
35
-    foreach($error_dump as $key => $value) {
34
+  if (is_array($error_dump)) {
35
+    foreach ($error_dump as $key => $value) {
36 36
       $v = array(
37 37
         'VAR_NAME'  => $key,
38 38
         'VAR_VALUE' => $key == 'query_log' ? $value : dump($value, $key)
@@ -47,10 +47,10 @@  discard block
 block discarded – undo
47 47
 
48 48
   $i = 0;
49 49
   $query = db_log_list_get_last_100();
50
-  while($u = db_fetch($query)) {
50
+  while ($u = db_fetch($query)) {
51 51
     $i++;
52 52
     $v = array();
53
-    foreach($u as $key => $value) {
53
+    foreach ($u as $key => $value) {
54 54
       $v[strtoupper($key)] = $value;
55 55
     }
56 56
     $template->assign_block_vars('error', $v);
Please login to merge, or discard this patch.
admin/banned.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -14,9 +14,9 @@  discard block
 block discarded – undo
14 14
 define('INSTALL', false);
15 15
 define('IN_ADMIN', true);
16 16
 
17
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
17
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
18 18
 
19
-if($user['authlevel'] < 1) {
19
+if ($user['authlevel'] < 1) {
20 20
   AdminMessage(classLocale::$lang['adm_err_denied']);
21 21
 }
22 22
 
@@ -28,8 +28,8 @@  discard block
 block discarded – undo
28 28
 $template = gettemplate("admin/admin_ban", true);
29 29
 
30 30
 $player_banned_row = db_user_by_username($name_unsafe);
31
-if($mode == 'banit' && $action) {
32
-  if($player_banned_row) {
31
+if ($mode == 'banit' && $action) {
32
+  if ($player_banned_row) {
33 33
     $reas = $_POST['why'];
34 34
     $days = $_POST['days'];
35 35
     $hour = $_POST['hour'];
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
     $adm_bn_thpl = classLocale::$lang['adm_bn_thpl'];
50 50
     $DoneMessage = "{$adm_bn_thpl} {$name_output} {$adm_bn_isbn}";
51 51
 
52
-    if($is_vacation) {
52
+    if ($is_vacation) {
53 53
       $DoneMessage .= classLocale::$lang['adm_bn_vctn'];
54 54
     }
55 55
 
@@ -59,10 +59,10 @@  discard block
 block discarded – undo
59 59
   }
60 60
 
61 61
   AdminMessage($DoneMessage, classLocale::$lang['adm_ban_title']);
62
-} elseif($mode == 'unbanit' && $action) {
62
+} elseif ($mode == 'unbanit' && $action) {
63 63
   sys_admin_player_ban_unset($user, $player_banned_row, ($reason = sys_get_param_str('why')) ? $reason : classLocale::$lang['sys_unbanned']);
64 64
 
65
-  $DoneMessage = classLocale::$lang['adm_unbn_thpl'] . " " . $name_output . " " . classLocale::$lang['adm_unbn_isbn'];
65
+  $DoneMessage = classLocale::$lang['adm_unbn_thpl']." ".$name_output." ".classLocale::$lang['adm_unbn_isbn'];
66 66
   AdminMessage($DoneMessage, classLocale::$lang['adm_unbn_ttle']);
67 67
 };
68 68
 
Please login to merge, or discard this patch.
admin/adm_payment.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -12,9 +12,9 @@  discard block
 block discarded – undo
12 12
 define('INSTALL', false);
13 13
 define('IN_ADMIN', true);
14 14
 
15
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
15
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
16 16
 
17
-if($user['authlevel'] < 3) {
17
+if ($user['authlevel'] < 3) {
18 18
   AdminMessage(classLocale::$lang['adm_err_denied']);
19 19
 }
20 20
 
@@ -25,8 +25,8 @@  discard block
 block discarded – undo
25 25
 );
26 26
 
27 27
 $query = db_payment_list_payers();
28
-while($row = db_fetch($query)) {
29
-  $payer_list[$row['payment_user_id']] = '[' . $row['payment_user_id'] . '] ' . $row['payment_user_name'];
28
+while ($row = db_fetch($query)) {
29
+  $payer_list[$row['payment_user_id']] = '['.$row['payment_user_id'].'] '.$row['payment_user_name'];
30 30
 }
31 31
 tpl_assign_select($template, 'payer', $payer_list);
32 32
 
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 );
36 36
 
37 37
 $query = db_payment_list_modules();
38
-while($row = db_fetch($query)) {
38
+while ($row = db_fetch($query)) {
39 39
   $module_list[$row['payment_module_name']] = $row['payment_module_name'];
40 40
 }
41 41
 tpl_assign_select($template, 'module', $module_list);
@@ -50,9 +50,9 @@  discard block
 block discarded – undo
50 50
 
51 51
 $query = db_payment_list_get($flt_payer, $flt_status, $flt_test, $flt_module);
52 52
 
53
-while($row = db_fetch($query)) {
53
+while ($row = db_fetch($query)) {
54 54
   $row2 = array();
55
-  foreach($row as $key => $value) {
55
+  foreach ($row as $key => $value) {
56 56
     $row2[strtoupper($key)] = $value;
57 57
   }
58 58
   $template->assign_block_vars('payment', $row2);
Please login to merge, or discard this patch.
admin/planet_edit.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -4,16 +4,16 @@  discard block
 block discarded – undo
4 4
 define('INSTALL', false);
5 5
 define('IN_ADMIN', true);
6 6
 
7
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
7
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
8 8
 
9 9
 // if($user['authlevel'] < 2)
10
-if($user['authlevel'] < 3)
10
+if ($user['authlevel'] < 3)
11 11
 {
12 12
   AdminMessage(classLocale::$lang['adm_err_denied']);
13 13
 }
14 14
 AdminMessage('Временно не работает');
15 15
 
16
-require("includes/admin_planet_edit.inc" . DOT_PHP_EX);
16
+require("includes/admin_planet_edit.inc".DOT_PHP_EX);
17 17
 
18 18
 $template = gettemplate('admin/admin_planet_edit', true);
19 19
 
@@ -21,30 +21,30 @@  discard block
 block discarded – undo
21 21
 $planet_id = sys_get_param_id('planet_id');
22 22
 
23 23
 $unit_list = sys_get_param('unit_list');
24
-if(sys_get_param('change_data') && !empty($unit_list))
24
+if (sys_get_param('change_data') && !empty($unit_list))
25 25
 {
26 26
   $query_string = array();
27
-  foreach($unit_list as $unit_id => $unit_amount)
27
+  foreach ($unit_list as $unit_id => $unit_amount)
28 28
   {
29
-    if($unit_query_string = admin_planet_edit_query_string($unit_id, $unit_amount, $mode))
29
+    if ($unit_query_string = admin_planet_edit_query_string($unit_id, $unit_amount, $mode))
30 30
     {
31 31
       $query_string[] = $unit_query_string;
32 32
     }
33 33
   }
34 34
 
35
-  if(!empty($query_string))
35
+  if (!empty($query_string))
36 36
   {
37 37
     db_planet_set_by_id($planet_id, implode(', ', $query_string));
38 38
   }
39 39
 }
40 40
 
41
-if($planet_id)
41
+if ($planet_id)
42 42
 {
43 43
   $edit_planet_row = db_planet_by_id($planet_id);
44 44
   admin_planet_edit_template($template, $edit_planet_row, $mode);
45 45
 }
46 46
 
47
-foreach($admin_planet_edit_mode_list as $page_mode => $mode_locale)
47
+foreach ($admin_planet_edit_mode_list as $page_mode => $mode_locale)
48 48
 {
49 49
   $template->assign_block_vars('page_menu', array(
50 50
     'ID' => $page_mode,
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
 $template->assign_vars(array(
56 56
   'MODE' => $mode,
57 57
   'PLANET_ID' => $planet_id,
58
-  'PLANET_NAME' => empty($edit_planet_row) ? '' : classLocale::$lang['sys_planet_type'][$edit_planet_row['planet_type']] . ' ' . uni_render_planet($edit_planet_row),
58
+  'PLANET_NAME' => empty($edit_planet_row) ? '' : classLocale::$lang['sys_planet_type'][$edit_planet_row['planet_type']].' '.uni_render_planet($edit_planet_row),
59 59
   'PAGE_HINT' => classLocale::$lang['adm_planet_edit_hint'],
60 60
 ));
61 61
 
Please login to merge, or discard this patch.
admin/add_moon.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -11,17 +11,17 @@
 block discarded – undo
11 11
 define('INSTALL', false);
12 12
 define('IN_ADMIN', true);
13 13
 
14
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
14
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
15 15
 
16 16
 // if ($user['authlevel'] < 2)
17
-if($user['authlevel'] < 3)
17
+if ($user['authlevel'] < 3)
18 18
 {
19 19
   AdminMessage(classLocale::$lang['adm_err_denied']);
20 20
 }
21 21
 
22 22
 $template = gettemplate("admin/add_moon", true);
23 23
 
24
-if(sys_get_param_str('mode') == 'addit')
24
+if (sys_get_param_str('mode') == 'addit')
25 25
 {
26 26
   $PlanetID = sys_get_param_id('user');
27 27
   $MoonName = sys_get_param_str('name');
Please login to merge, or discard this patch.
admin/admin_chat.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -12,15 +12,15 @@  discard block
 block discarded – undo
12 12
 define('INSTALL', false);
13 13
 define('IN_ADMIN', true);
14 14
 
15
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
15
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
16 16
 
17
-if($user['authlevel'] < 3) {
17
+if ($user['authlevel'] < 3) {
18 18
   AdminMessage(classLocale::$lang['adm_err_denied']);
19 19
 }
20 20
 
21
-if($delete = sys_get_param_str('delete')) {
21
+if ($delete = sys_get_param_str('delete')) {
22 22
   db_chat_message_delete($delete);
23
-} elseif(sys_get_param_str('deleteall') == 'yes') {
23
+} elseif (sys_get_param_str('deleteall') == 'yes') {
24 24
   db_chat_message_purge();
25 25
 }
26 26
 
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 
29 29
 $query = db_chat_message_get_last_25();
30 30
 $i = 0;
31
-while($e = db_fetch($query)) {
31
+while ($e = db_fetch($query)) {
32 32
   $i++;
33 33
   $template->assign_block_vars('messages', array(
34 34
     'ID' => $e['messageid'],
Please login to merge, or discard this patch.
admin/maintenance.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
 define('INSTALL', false);
11 11
 define('IN_ADMIN', true);
12 12
 
13
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
13
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
14 14
 
15 15
 if ($user['authlevel'] < 3)
16 16
 {
@@ -26,4 +26,4 @@  discard block
 block discarded – undo
26 26
 });
27 27
 </script>';
28 28
 
29
-AdminMessage($script . '<img src=design/images/progressbar.gif><br>' . classLocale::$lang['sys_wait'], classLocale::$lang['adm_maintenance_title']);
29
+AdminMessage($script.'<img src=design/images/progressbar.gif><br>'.classLocale::$lang['sys_wait'], classLocale::$lang['adm_maintenance_title']);
Please login to merge, or discard this patch.
admin/admin_user.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -3,22 +3,22 @@  discard block
 block discarded – undo
3 3
 define('INSIDE', true);
4 4
 define('INSTALL', false);
5 5
 define('IN_ADMIN', true);
6
-require('../common.' . substr(strrchr(__FILE__, '.'), 1));
6
+require('../common.'.substr(strrchr(__FILE__, '.'), 1));
7 7
 
8
-if($user['authlevel'] < 3) {
8
+if ($user['authlevel'] < 3) {
9 9
   AdminMessage(classLocale::$lang['adm_err_denied']);
10 10
 }
11 11
 
12 12
 lng_include('admin');
13 13
 
14 14
 $user_id = sys_get_param_id('uid');
15
-if(!($user_row = db_user_by_id($user_id))) {
15
+if (!($user_row = db_user_by_id($user_id))) {
16 16
   AdminMessage(sprintf(classLocale::$lang['adm_dm_user_none'], $user_id));
17 17
 }
18 18
 
19 19
 $template = gettemplate('admin/admin_user', true);
20 20
 
21
-if(!empty($user_row['user_last_browser_id'])) {
21
+if (!empty($user_row['user_last_browser_id'])) {
22 22
   $user_row['browser_user_agent'] = db_browser_agent_get_by_id($user_row['user_last_browser_id']);
23 23
 }
24 24
 
@@ -54,10 +54,10 @@  discard block
 block discarded – undo
54 54
     'raidsloose',
55 55
     'raidswin',
56 56
     'total_rank',
57
-    'total_points',  ),
57
+    'total_points',),
58 58
 );
59
-foreach($formats as $callable => $field_list) {
60
-  foreach($field_list as $field_name) {
59
+foreach ($formats as $callable => $field_list) {
60
+  foreach ($field_list as $field_name) {
61 61
     $user_row[$field_name] = call_user_func($callable, $user_row[$field_name]);
62 62
   }
63 63
 }
Please login to merge, or discard this patch.