Test Failed
Branch trunk (412648)
by SuperNova.WS
03:40
created
classes/DBAL/ActiveRecordAbstract.php 1 patch
Doc Comments   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
   }
95 95
 
96 96
   /**
97
-   * @return array[]
97
+   * @return \array[]
98 98
    */
99 99
   protected static function dbGetTableFields() {
100 100
     return static::db()->schema()->getTableSchema(static::tableName())->fields;
@@ -118,7 +118,6 @@  discard block
 block discarded – undo
118 118
   /**
119 119
    * Instate ActiveRecord from array of field values - even if it is empty
120 120
    *
121
-   * @param array $fields List of field values [$propertyName => $propertyValue]
122 121
    *
123 122
    * @return static
124 123
    */
@@ -132,7 +131,6 @@  discard block
 block discarded – undo
132 131
   /**
133 132
    * Instate ActiveRecord from array of field values
134 133
    *
135
-   * @param array $fields List of field values [$propertyName => $propertyValue]
136 134
    *
137 135
    * @return static|bool
138 136
    */
@@ -618,7 +616,7 @@  discard block
 block discarded – undo
618 616
    * DOES NOT override existing values
619 617
    * DOES set default values for empty fields
620 618
    *
621
-   * @param array $fields List of field values [$fieldName => $fieldValue]
619
+   * @param string[] $fields List of field values [$fieldName => $fieldValue]
622 620
    */
623 621
   protected function fromFields(array $fields) {
624 622
     $this->fromProperties(static::translateNames($fields, self::FIELDS_TO_PROPERTIES));
Please login to merge, or discard this patch.
classes/DBAL/TableSchema.php 1 patch
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,6 @@
 block discarded – undo
37 37
    * TableSchema constructor.
38 38
    *
39 39
    * @param string         $tableName
40
-   * @param \db_mysql|null $db
41 40
    */
42 41
   public function __construct($tableName, Schema $dbSchema) {
43 42
     $this->dbSchema = $dbSchema;
Please login to merge, or discard this patch.
classes/HelperArray.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
   /**
42 42
    * Convert $delimiter delimited string to array
43 43
    *
44
-   * @param mixed  $string
45
-   * @param string $delimiter
44
+   * @param string  $string
45
+   * @param string string
46 46
    *
47 47
    * @return array
48 48
    */
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -240,7 +240,7 @@  discard block
 block discarded – undo
240 240
    * @return array
241 241
    */
242 242
   public static function parseParamStrings($array, $delimiter = '=') {
243
-    !is_array($array) ? $array = array((string)$array) : false;
243
+    !is_array($array) ? $array = array((string) $array) : false;
244 244
 
245 245
     $result = array();
246 246
     foreach ($array as $param) {
@@ -262,8 +262,8 @@  discard block
 block discarded – undo
262 262
    * @return float|null
263 263
    */
264 264
   public static function maxValueByField(&$array, $fieldName) {
265
-    return array_reduce($array, function ($carry, $item) use ($fieldName) {
266
-      if(is_array($item) && isset($item[$fieldName]) && (!isset($carry) || $carry < $item[$fieldName])) {
265
+    return array_reduce($array, function($carry, $item) use ($fieldName) {
266
+      if (is_array($item) && isset($item[$fieldName]) && (!isset($carry) || $carry < $item[$fieldName])) {
267 267
         $carry = $item[$fieldName];
268 268
       }
269 269
 
@@ -280,8 +280,8 @@  discard block
 block discarded – undo
280 280
 
281 281
     return
282 282
       array_reduce($array,
283
-        function ($carry, $item) use (&$fieldName, $maxValue) {
284
-          if(is_array($item) && isset($item[$fieldName]) && $item[$fieldName] == $maxValue) {
283
+        function($carry, $item) use (&$fieldName, $maxValue) {
284
+          if (is_array($item) && isset($item[$fieldName]) && $item[$fieldName] == $maxValue) {
285 285
             $carry[] = $item;
286 286
           }
287 287
 
@@ -292,7 +292,7 @@  discard block
 block discarded – undo
292 292
   }
293 293
 
294 294
   public static function intersectByKeys(array &$array1, array &$array2) {
295
-    return array_uintersect_assoc($array1, $array2, function ($a, $b) {return 0;});
295
+    return array_uintersect_assoc($array1, $array2, function($a, $b) {return 0; });
296 296
   }
297 297
 
298 298
 }
Please login to merge, or discard this patch.
includes/constants.php 1 patch
Spacing   +242 added lines, -242 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-if(defined('__SN_CONSTANTS_DEFINED') && __SN_CONSTANTS_DEFINED === true) {
3
+if (defined('__SN_CONSTANTS_DEFINED') && __SN_CONSTANTS_DEFINED === true) {
4 4
   return;
5 5
 }
6 6
 
@@ -35,7 +35,7 @@  discard block
 block discarded – undo
35 35
 define('SN_ROOT_VIRTUAL', 'http' . (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] == 'on' ? 's' : '') . '://' . $_server_http_host . SN_ROOT_RELATIVE);
36 36
 
37 37
 $_server_server_name = isset($_SERVER['SERVER_NAME']) ? $_SERVER['SERVER_NAME'] : '';
38
-if(strpos(strtolower($_server_server_name), 'google.') !== false) {
38
+if (strpos(strtolower($_server_server_name), 'google.') !== false) {
39 39
   define('SN_GOOGLE', true);
40 40
 }
41 41
 define('SN_ROOT_VIRTUAL_PARENT', str_replace('//google.', '//', SN_ROOT_VIRTUAL));
@@ -54,8 +54,8 @@  discard block
 block discarded – undo
54 54
 
55 55
 // Game type constants starts with GAME_
56 56
 define('GAME_SUPERNOVA', 0);
57
-define('GAME_OGAME'    , 1);
58
-define('GAME_BLITZ'    , 2);
57
+define('GAME_OGAME', 1);
58
+define('GAME_BLITZ', 2);
59 59
 
60 60
 // Date & time range constants
61 61
 define('DATE_FOREVER', 2000000000);
@@ -68,14 +68,14 @@  discard block
 block discarded – undo
68 68
 define('PERIOD_YEAR', PERIOD_DAY * 365);
69 69
 define('PERIOD_FOREVER', PERIOD_YEAR * 100);
70 70
 
71
-define('PERIOD_MINUTE_2' , PERIOD_MINUTE * 2);
72
-define('PERIOD_MINUTE_3' , PERIOD_MINUTE * 3);
73
-define('PERIOD_MINUTE_5' , PERIOD_MINUTE * 5);
71
+define('PERIOD_MINUTE_2', PERIOD_MINUTE * 2);
72
+define('PERIOD_MINUTE_3', PERIOD_MINUTE * 3);
73
+define('PERIOD_MINUTE_5', PERIOD_MINUTE * 5);
74 74
 define('PERIOD_MINUTE_10', PERIOD_MINUTE * 10);
75
-define('PERIOD_DAY_3'    , PERIOD_DAY * 3);
76
-define('PERIOD_WEEK_2'   , PERIOD_WEEK * 2);
77
-define('PERIOD_MONTH_2'  , PERIOD_MONTH * 2);
78
-define('PERIOD_MONTH_3'  , PERIOD_MONTH * 3);
75
+define('PERIOD_DAY_3', PERIOD_DAY * 3);
76
+define('PERIOD_WEEK_2', PERIOD_WEEK * 2);
77
+define('PERIOD_MONTH_2', PERIOD_MONTH * 2);
78
+define('PERIOD_MONTH_3', PERIOD_MONTH * 3);
79 79
 
80 80
 define('FONT_SIZE_PERCENT_MIN', 56.25);
81 81
 define('FONT_SIZE_PERCENT_DEFAULT', 68.75);
@@ -129,38 +129,38 @@  discard block
 block discarded – undo
129 129
 
130 130
 // Mot qui sont interdit a la saisie !
131 131
 global $ListCensure;
132
-$ListCensure = array ( '/</', '/>/', '/script/i', '/doquery/i', '/http/i', '/javascript/i');
132
+$ListCensure = array('/</', '/>/', '/script/i', '/doquery/i', '/http/i', '/javascript/i');
133 133
 
134 134
 // Confirmation record types
135
-define('CONFIRM_REGISTRATION'  , 1);
135
+define('CONFIRM_REGISTRATION', 1);
136 136
 define('CONFIRM_PASSWORD_RESET', 2);
137
-define('CONFIRM_DELETE'        , 3);
137
+define('CONFIRM_DELETE', 3);
138 138
 
139 139
 define('AFFILIATE_MM_TO_REFERRAL_DM', 2);
140 140
 
141 141
 // Ally diplomacy statuses
142
-define('ALLY_DIPLOMACY_SELF'         , 'self');
143
-define('ALLY_DIPLOMACY_NEUTRAL'      , 'neutral');
144
-define('ALLY_DIPLOMACY_WAR'          , 'war');
145
-define('ALLY_DIPLOMACY_PEACE'        , 'peace');
142
+define('ALLY_DIPLOMACY_SELF', 'self');
143
+define('ALLY_DIPLOMACY_NEUTRAL', 'neutral');
144
+define('ALLY_DIPLOMACY_WAR', 'war');
145
+define('ALLY_DIPLOMACY_PEACE', 'peace');
146 146
 define('ALLY_DIPLOMACY_CONFEDERATION', 'confederation');
147
-define('ALLY_DIPLOMACY_FEDERATION'   , 'federation');
148
-define('ALLY_DIPLOMACY_UNION'        , 'union');
149
-define('ALLY_DIPLOMACY_MASTER'       , 'master');
150
-define('ALLY_DIPLOMACY_SLAVE'        , 'slave');
147
+define('ALLY_DIPLOMACY_FEDERATION', 'federation');
148
+define('ALLY_DIPLOMACY_UNION', 'union');
149
+define('ALLY_DIPLOMACY_MASTER', 'master');
150
+define('ALLY_DIPLOMACY_SLAVE', 'slave');
151 151
 
152 152
 define('ALLY_PROPOSE_SEND', 0);
153 153
 
154 154
 // Quest types
155
-define('QUEST_TYPE_BUILD'   , 1);
155
+define('QUEST_TYPE_BUILD', 1);
156 156
 define('QUEST_TYPE_RESEARCH', 2);
157
-define('QUEST_TYPE_COMBAT'  , 3);
157
+define('QUEST_TYPE_COMBAT', 3);
158 158
 
159
-define('QUEST_STATUS_EXCEPT_COMPLETE' , -2);
160
-define('QUEST_STATUS_ALL' , -1);
161
-define('QUEST_STATUS_NOT_STARTED' , 0);
162
-define('QUEST_STATUS_STARTED'     , 1);
163
-define('QUEST_STATUS_COMPLETE'    , 2);
159
+define('QUEST_STATUS_EXCEPT_COMPLETE', -2);
160
+define('QUEST_STATUS_ALL', -1);
161
+define('QUEST_STATUS_NOT_STARTED', 0);
162
+define('QUEST_STATUS_STARTED', 1);
163
+define('QUEST_STATUS_COMPLETE', 2);
164 164
 
165 165
 define('TYPE_EMPTY', '');
166 166
 define('TYPE_INTEGER', 'integer');
@@ -173,66 +173,66 @@  discard block
 block discarded – undo
173 173
 
174 174
 // *** Combat-related constants
175 175
 // *** Mission Type constants starts with MT_
176
-define('MT_NONE'     ,  0);
177
-define('MT_ATTACK'   ,  1);
178
-define('MT_AKS'      ,  2);
179
-define('MT_TRANSPORT',  3);
180
-define('MT_RELOCATE' ,  4);
181
-define('MT_HOLD'     ,  5);
182
-define('MT_SPY'      ,  6);
183
-define('MT_COLONIZE' ,  7);
184
-define('MT_RECYCLE'  ,  8);
185
-define('MT_DESTROY'  ,  9);
186
-define('MT_MISSILE'  , 10);
187
-define('MT_EXPLORE'  , 15);
176
+define('MT_NONE', 0);
177
+define('MT_ATTACK', 1);
178
+define('MT_AKS', 2);
179
+define('MT_TRANSPORT', 3);
180
+define('MT_RELOCATE', 4);
181
+define('MT_HOLD', 5);
182
+define('MT_SPY', 6);
183
+define('MT_COLONIZE', 7);
184
+define('MT_RECYCLE', 8);
185
+define('MT_DESTROY', 9);
186
+define('MT_MISSILE', 10);
187
+define('MT_EXPLORE', 15);
188 188
 
189 189
 // *** Planet Target constants starts with PT_
190 190
 define('PT_NONE', 0);
191 191
 define('PT_ALL', 0);
192 192
 define('PT_PLANET', 1);
193 193
 define('PT_DEBRIS', 2);
194
-define('PT_MOON'  , 3);
194
+define('PT_MOON', 3);
195 195
 
196 196
 // *** Unit locations - shows db table where unit belong
197 197
 // Also cache indexes
198
-define('LOC_NONE',    -1);
198
+define('LOC_NONE', -1);
199 199
 define('LOC_UNIVERSE', 0);
200
-define('LOC_PLANET',   1);
201
-define('LOC_DEBRIS',   2); // Translates to `planets` table planet_type = 1, `debris_*` fields
202
-define('LOC_MOON',     3); // Translates to `planets` table planet_type = 3
203
-define('LOC_USER',     4);
204
-define('LOC_FLEET',    5);
205
-define('LOC_ALLY',     6);
200
+define('LOC_PLANET', 1);
201
+define('LOC_DEBRIS', 2); // Translates to `planets` table planet_type = 1, `debris_*` fields
202
+define('LOC_MOON', 3); // Translates to `planets` table planet_type = 3
203
+define('LOC_USER', 4);
204
+define('LOC_FLEET', 5);
205
+define('LOC_ALLY', 6);
206 206
 
207 207
 // ТОЛЬКО ВНУТРЕНЕЕ!!!
208
-define('LOC_UNIT',    'LOC_UNIT');
209
-define('LOC_QUE',     'LOC_QUE');
210
-define('LOC_LOCATION','LOC_LOCATION');
211
-define('LOC_LOCKS','LOC_LOCKS');
208
+define('LOC_UNIT', 'LOC_UNIT');
209
+define('LOC_QUE', 'LOC_QUE');
210
+define('LOC_LOCATION', 'LOC_LOCATION');
211
+define('LOC_LOCKS', 'LOC_LOCKS');
212 212
 
213 213
 // *** Caching masks
214
-define('CACHE_NOTHING'    ,  0);
215
-define('CACHE_FLEET'      ,  1);
216
-define('CACHE_PLANET'     ,  2);
217
-define('CACHE_USER'       ,  4);
218
-define('CACHE_SOURCE'     ,  8);
214
+define('CACHE_NOTHING', 0);
215
+define('CACHE_FLEET', 1);
216
+define('CACHE_PLANET', 2);
217
+define('CACHE_USER', 4);
218
+define('CACHE_SOURCE', 8);
219 219
 define('CACHE_DESTINATION', 16);
220
-define('CACHE_EVENT'      , 32);
220
+define('CACHE_EVENT', 32);
221 221
 
222
-define('CACHE_USER_SRC'  , CACHE_USER | CACHE_SOURCE);
223
-define('CACHE_USER_DST'  , CACHE_USER | CACHE_DESTINATION);
222
+define('CACHE_USER_SRC', CACHE_USER | CACHE_SOURCE);
223
+define('CACHE_USER_DST', CACHE_USER | CACHE_DESTINATION);
224 224
 define('CACHE_PLANET_SRC', CACHE_PLANET | CACHE_SOURCE);
225 225
 define('CACHE_PLANET_DST', CACHE_PLANET | CACHE_DESTINATION);
226
-define('CACHE_COMBAT'    , CACHE_FLEET | CACHE_PLANET | CACHE_USER | CACHE_SOURCE | CACHE_DESTINATION);
226
+define('CACHE_COMBAT', CACHE_FLEET | CACHE_PLANET | CACHE_USER | CACHE_SOURCE | CACHE_DESTINATION);
227 227
 
228
-define('CACHE_ALL'       , CACHE_FLEET | CACHE_PLANET | CACHE_USER | CACHE_SOURCE | CACHE_DESTINATION | CACHE_EVENT);
228
+define('CACHE_ALL', CACHE_FLEET | CACHE_PLANET | CACHE_USER | CACHE_SOURCE | CACHE_DESTINATION | CACHE_EVENT);
229 229
 
230
-define('CACHE_NONE'      , CACHE_NOTHING); // Alias for me
230
+define('CACHE_NONE', CACHE_NOTHING); // Alias for me
231 231
 
232 232
 // *** Event types
233 233
 define('EVENT_FLEET_NONE', 0);
234 234
 define('EVENT_FLEET_ARRIVE', 1);
235
-define('EVENT_FLEET_STAY'  , 2);
235
+define('EVENT_FLEET_STAY', 2);
236 236
 define('EVENT_FLEET_RETURN', 3);
237 237
 
238 238
 // *** Constants for changing DM
@@ -289,11 +289,11 @@  discard block
 block discarded – undo
289 289
 
290 290
 
291 291
 // Operation error status HARDCODE!
292
-define('ERR_NONE'               , 0); // No error
293
-define('ERR_WARNING'            , 1); // There is warning - something altering normal operation process
294
-define('ERR_ERROR'              , 2); // There is error - something permits operation from process
295
-define('ERR_HACK'               , 4); // Operation is qualified as hack attempt
296
-define('ERR_NOTICE'             , 8); // There is notice - nothing really critical but operator should know
292
+define('ERR_NONE', 0); // No error
293
+define('ERR_WARNING', 1); // There is warning - something altering normal operation process
294
+define('ERR_ERROR', 2); // There is error - something permits operation from process
295
+define('ERR_HACK', 4); // Operation is qualified as hack attempt
296
+define('ERR_NOTICE', 8); // There is notice - nothing really critical but operator should know
297 297
 // New GLOBAL operation results
298 298
 //define('RESULT_DEFAULT' , 0); // Default result - all went OK or result really doesn't matter
299 299
 //define('RESULT_WARNING' , 1);
@@ -313,7 +313,7 @@  discard block
 block discarded – undo
313 313
 define('SN_PAYMENT_REQUEST_OK', 0);
314 314
 define('SN_PAYMENT_REQUEST_ERROR_UNIT_AMOUNT', 1);
315 315
 define('SN_PAYMENT_REQUEST_ERROR_PAYLINK_UNSUPPORTED', 2);
316
-define('SN_PAYMENT_REQUEST_IP_WRONG', 3);  // Неправильный IP входящей системы - обычно хак
316
+define('SN_PAYMENT_REQUEST_IP_WRONG', 3); // Неправильный IP входящей системы - обычно хак
317 317
 define('SN_PAYMENT_REQUEST_COMMAND_UNSUPPORTED', 4); // Неподдерживаемая команда - обычно хак
318 318
 define('SN_PAYMENT_REQUEST_SIGNATURE_INVALID', 5); // Неправильная подпись или не сошлась контрольная сумма - обычно хак
319 319
 define('SN_MODULE_DISABLED', 6); // Модуль отключен // УНИВЕРСАЛЬНЫЙ ОТВЕТ!
@@ -589,16 +589,16 @@  discard block
 block discarded – undo
589 589
 //define('F_DEVICE_ID',     'F_DEVICE_ID');
590 590
 //define('F_DEVICE_CYPHER', 'F_DEVICE_CYPHER');
591 591
 
592
-define('F_PROVIDER_ID',   'F_PROVIDER_ID');
592
+define('F_PROVIDER_ID', 'F_PROVIDER_ID');
593 593
 // define('F_PROVIDER_LIST', 'F_PROVIDER_LIST');
594 594
 
595 595
 define('F_IMPERSONATE_STATUS', 'F_IMPERSONATE_STATUS');
596 596
 define('F_IMPERSONATE_OPERATOR', 'F_IMPERSONATE_OPERATOR');
597 597
 
598
-define('F_LOGIN_STATUS',  'F_LOGIN_STATUS');
598
+define('F_LOGIN_STATUS', 'F_LOGIN_STATUS');
599 599
 define('F_LOGIN_MESSAGE', 'F_LOGIN_MESSAGE');
600 600
 
601
-define('F_PLAYER_REGISTER_STATUS',  'F_PLAYER_REGISTER_STATUS');
601
+define('F_PLAYER_REGISTER_STATUS', 'F_PLAYER_REGISTER_STATUS');
602 602
 define('F_PLAYER_REGISTER_MESSAGE', 'F_PLAYER_REGISTER_MESSAGE');
603 603
 
604 604
 define('F_USER_ID', 'F_USER_ID');
@@ -642,78 +642,78 @@  discard block
 block discarded – undo
642 642
 
643 643
 
644 644
 // Option groups
645
-define('OPT_ALL',      0);
646
-define('OPT_MESSAGE',  1);
645
+define('OPT_ALL', 0);
646
+define('OPT_MESSAGE', 1);
647 647
 define('OPT_UNIVERSE', 2);
648 648
 define('OPT_INTERFACE', 3);
649 649
 
650 650
 // Message classes
651
-define('MSG_TYPE_OUTBOX'   ,  -1);
652
-define('MSG_TYPE_SPY'      ,   0);
653
-define('MSG_TYPE_PLAYER'   ,   1);
654
-define('MSG_TYPE_ALLIANCE' ,   2);
655
-define('MSG_TYPE_COMBAT'   ,   3);
656
-define('MSG_TYPE_RECYCLE'  ,   4);
657
-define('MSG_TYPE_TRANSPORT',   5);
658
-define('MSG_TYPE_ADMIN'    ,   6);
659
-define('MSG_TYPE_EXPLORE'  ,  15);
660
-define('MSG_TYPE_QUE'      ,  99);
661
-define('MSG_TYPE_NEW'      , 100);
651
+define('MSG_TYPE_OUTBOX', -1);
652
+define('MSG_TYPE_SPY', 0);
653
+define('MSG_TYPE_PLAYER', 1);
654
+define('MSG_TYPE_ALLIANCE', 2);
655
+define('MSG_TYPE_COMBAT', 3);
656
+define('MSG_TYPE_RECYCLE', 4);
657
+define('MSG_TYPE_TRANSPORT', 5);
658
+define('MSG_TYPE_ADMIN', 6);
659
+define('MSG_TYPE_EXPLORE', 15);
660
+define('MSG_TYPE_QUE', 99);
661
+define('MSG_TYPE_NEW', 100);
662 662
 
663 663
 // Attack verification statuses
664
-define('ATTACK_ALLOWED'           ,  0);
665
-define('ATTACK_NO_TARGET'         ,  1);
666
-define('ATTACK_OWN'               ,  2);
667
-define('ATTACK_WRONG_MISSION'     ,  3);
668
-define('ATTACK_NO_ALLY_DEPOSIT'   ,  4);
669
-define('ATTACK_NO_DEBRIS'         ,  5);
670
-define('ATTACK_VACATION'          ,  6);
671
-define('ATTACK_SAME_IP'           ,  7);
672
-define('ATTACK_BUFFING'           ,  8);
673
-define('ATTACK_ADMIN'             ,  9);
674
-define('ATTACK_NOOB'              , 10);
675
-define('ATTACK_OWN_VACATION'      , 11);
676
-define('ATTACK_NO_SILO'           , 12);
677
-define('ATTACK_NO_MISSILE'        , 13);
678
-define('ATTACK_NO_FLEET'          , 14);
679
-define('ATTACK_NO_SLOTS'          , 15);
680
-define('ATTACK_NO_SHIPS'          , 16);
681
-define('ATTACK_NO_RECYCLERS'      , 17);
682
-define('ATTACK_NO_SPIES'          , 18);
683
-define('ATTACK_NO_COLONIZER'      , 19);
684
-define('ATTACK_MISSILE_TOO_FAR'   , 20);
685
-define('ATTACK_WRONG_STRUCTURE'   , 21);
686
-define('ATTACK_NO_FUEL'           , 22);
687
-define('ATTACK_NO_RESOURCES'      , 23);
688
-define('ATTACK_NO_ACS'            , 24);
689
-define('ATTACK_ACS_MISSTARGET'    , 25);
690
-define('ATTACK_WRONG_SPEED'       , 26);
691
-define('ATTACK_ACS_TOO_LATE'      , 27);
692
-define('ATTACK_BASHING'           , 28);
693
-define('ATTACK_BASHING_WAR_DELAY' , 29);
694
-define('ATTACK_ACS_WRONG_TARGET'  , 30);
695
-define('ATTACK_SAME'              , 31);
664
+define('ATTACK_ALLOWED', 0);
665
+define('ATTACK_NO_TARGET', 1);
666
+define('ATTACK_OWN', 2);
667
+define('ATTACK_WRONG_MISSION', 3);
668
+define('ATTACK_NO_ALLY_DEPOSIT', 4);
669
+define('ATTACK_NO_DEBRIS', 5);
670
+define('ATTACK_VACATION', 6);
671
+define('ATTACK_SAME_IP', 7);
672
+define('ATTACK_BUFFING', 8);
673
+define('ATTACK_ADMIN', 9);
674
+define('ATTACK_NOOB', 10);
675
+define('ATTACK_OWN_VACATION', 11);
676
+define('ATTACK_NO_SILO', 12);
677
+define('ATTACK_NO_MISSILE', 13);
678
+define('ATTACK_NO_FLEET', 14);
679
+define('ATTACK_NO_SLOTS', 15);
680
+define('ATTACK_NO_SHIPS', 16);
681
+define('ATTACK_NO_RECYCLERS', 17);
682
+define('ATTACK_NO_SPIES', 18);
683
+define('ATTACK_NO_COLONIZER', 19);
684
+define('ATTACK_MISSILE_TOO_FAR', 20);
685
+define('ATTACK_WRONG_STRUCTURE', 21);
686
+define('ATTACK_NO_FUEL', 22);
687
+define('ATTACK_NO_RESOURCES', 23);
688
+define('ATTACK_NO_ACS', 24);
689
+define('ATTACK_ACS_MISSTARGET', 25);
690
+define('ATTACK_WRONG_SPEED', 26);
691
+define('ATTACK_ACS_TOO_LATE', 27);
692
+define('ATTACK_BASHING', 28);
693
+define('ATTACK_BASHING_WAR_DELAY', 29);
694
+define('ATTACK_ACS_WRONG_TARGET', 30);
695
+define('ATTACK_SAME', 31);
696 696
 define('ATTACK_RESOURCE_FORBIDDEN', 32);
697
-define('ATTACK_TRANSPORT_EMPTY'   , 33);
698
-define('ATTACK_SPIES_LONLY'       , 34);
699
-define('ATTACK_TOO_FAR'           , 35);
700
-define('ATTACK_OVERLOADED'        , 36);
701
-define('ATTACK_MISSION_ABSENT'    , 37);
702
-define('ATTACK_WRONG_UNIT'        , 38);
703
-define('ATTACK_ZERO_SPEED'        , 39);
704
-define('ATTACK_SHIP_COUNT_WRONG'  , 40);
697
+define('ATTACK_TRANSPORT_EMPTY', 33);
698
+define('ATTACK_SPIES_LONLY', 34);
699
+define('ATTACK_TOO_FAR', 35);
700
+define('ATTACK_OVERLOADED', 36);
701
+define('ATTACK_MISSION_ABSENT', 37);
702
+define('ATTACK_WRONG_UNIT', 38);
703
+define('ATTACK_ZERO_SPEED', 39);
704
+define('ATTACK_SHIP_COUNT_WRONG', 40);
705 705
 define('ATTACK_RESOURCE_COUNT_WRONG', 41);
706 706
 define('ATTACK_MORATORIUM', 42);
707 707
 define('ATTACK_CHILD_PROTECTION', 43);
708 708
 
709 709
 
710 710
 // *** Races - Homeworlds
711
-define('RACE_NONE'    , 0);
712
-define('RACE_EARTH'   , 1);
713
-define('RACE_MOON'    , 2);
714
-define('RACE_MERCURY' , 3);
715
-define('RACE_VENUS'   , 4);
716
-define('RACE_MARS'    , 5);
711
+define('RACE_NONE', 0);
712
+define('RACE_EARTH', 1);
713
+define('RACE_MOON', 2);
714
+define('RACE_MERCURY', 3);
715
+define('RACE_VENUS', 4);
716
+define('RACE_MARS', 5);
717 717
 define('RACE_ASTEROID', 6);
718 718
 // define('MARKET_INFO'         , 7);
719 719
 
@@ -721,114 +721,114 @@  discard block
 block discarded – undo
721 721
 
722 722
 // *** Market variables
723 723
 // === Market blocks
724
-define('MARKET_ENTRY'        , 0);
725
-define('MARKET_RESOURCES'    , 1);
726
-define('MARKET_SCRAPPER'     , 2);
727
-define('MARKET_STOCKMAN'     , 3);
728
-define('MARKET_EXCHANGE'     , 4);
729
-define('MARKET_BANKER'       , 5);
730
-define('MARKET_PAWNSHOP'     , 6);
731
-define('MARKET_INFO'         , 7);
724
+define('MARKET_ENTRY', 0);
725
+define('MARKET_RESOURCES', 1);
726
+define('MARKET_SCRAPPER', 2);
727
+define('MARKET_STOCKMAN', 3);
728
+define('MARKET_EXCHANGE', 4);
729
+define('MARKET_BANKER', 5);
730
+define('MARKET_PAWNSHOP', 6);
731
+define('MARKET_INFO', 7);
732 732
 
733 733
 // === Market error statuses
734
-define('MARKET_NOTHING'              ,  0);
735
-define('MARKET_DEAL'                 ,  1);
736
-define('MARKET_DEAL_TRADE'           ,  2);
737
-define('MARKET_NO_DM'                ,  3);
738
-define('MARKET_NO_RESOURCES'         ,  4);
739
-define('MARKET_ZERO_DEAL'            ,  5);
740
-define('MARKET_NO_SHIPS'             ,  6);
741
-define('MARKET_NOT_A_SHIP'           ,  7);
742
-define('MARKET_NO_STOCK'             ,  8);
743
-define('MARKET_ZERO_RES_STOCK'       ,  9);
744
-define('MARKET_NEGATIVE_SHIPS'       , 10);
745
-
746
-define('MARKET_INFO_PLAYER'          , 12);
747
-define('MARKET_INFO_WRONG'           , 11);
734
+define('MARKET_NOTHING', 0);
735
+define('MARKET_DEAL', 1);
736
+define('MARKET_DEAL_TRADE', 2);
737
+define('MARKET_NO_DM', 3);
738
+define('MARKET_NO_RESOURCES', 4);
739
+define('MARKET_ZERO_DEAL', 5);
740
+define('MARKET_NO_SHIPS', 6);
741
+define('MARKET_NOT_A_SHIP', 7);
742
+define('MARKET_NO_STOCK', 8);
743
+define('MARKET_ZERO_RES_STOCK', 9);
744
+define('MARKET_NEGATIVE_SHIPS', 10);
745
+
746
+define('MARKET_INFO_PLAYER', 12);
747
+define('MARKET_INFO_WRONG', 11);
748 748
 define('MARKET_INFO_PLAYER_NOT_FOUND', 13);
749
-define('MARKET_INFO_PLAYER_WRONG'    , 14);
750
-define('MARKET_INFO_PLAYER_SAME'     , 15);
749
+define('MARKET_INFO_PLAYER_WRONG', 14);
750
+define('MARKET_INFO_PLAYER_SAME', 15);
751 751
 
752 752
 
753 753
 
754 754
 
755 755
 // *** Mercenary/talent bonus types
756
-define('BONUS_NONE'    ,            0);  // No bonus
757
-define('BONUS_PERCENT' ,            1);  // Percent on base value
758
-define('BONUS_ADD'     ,            2);  // Add
759
-define('BONUS_ABILITY' ,            3);  // Some ability
760
-define('BONUS_MULTIPLY',            4);  // Multiply by value
761
-define('BONUS_PERCENT_CUMULATIVE' , 5);  // Cumulative percent on base value
762
-define('BONUS_PERCENT_DEGRADED' ,   6);  // Bonus amount degraded with increase as pow(bonus, level) (?)
763
-define('BONUS_SPEED',               7);  // Speed bonus
756
+define('BONUS_NONE', 0); // No bonus
757
+define('BONUS_PERCENT', 1); // Percent on base value
758
+define('BONUS_ADD', 2); // Add
759
+define('BONUS_ABILITY', 3); // Some ability
760
+define('BONUS_MULTIPLY', 4); // Multiply by value
761
+define('BONUS_PERCENT_CUMULATIVE', 5); // Cumulative percent on base value
762
+define('BONUS_PERCENT_DEGRADED', 6); // Bonus amount degraded with increase as pow(bonus, level) (?)
763
+define('BONUS_SPEED', 7); // Speed bonus
764 764
 
765 765
 // *** Action constant (build should be replaced with ACTION)
766
-define('BUILD_CREATE' ,  1);
766
+define('BUILD_CREATE', 1);
767 767
 define('BUILD_DESTROY', -1);
768 768
 define('BUILD_AUTOCONVERT', 2);
769 769
 
770
-define('ACTION_SELL'       , -1);
771
-define('ACTION_NOTHING'    ,  0);
772
-define('ACTION_BUY'        ,  1);
773
-define('ACTION_USE'        ,  2);
774
-define('ACTION_DELETE'     ,  3);
770
+define('ACTION_SELL', -1);
771
+define('ACTION_NOTHING', 0);
772
+define('ACTION_BUY', 1);
773
+define('ACTION_USE', 2);
774
+define('ACTION_DELETE', 3);
775 775
 
776 776
 // *** Check unit availability codes
777
-define('BUILD_ALLOWED'         , 0); // HARDCODED! DO NOT CHANGE!
777
+define('BUILD_ALLOWED', 0); // HARDCODED! DO NOT CHANGE!
778 778
 define('BUILD_REQUIRE_NOT_MEET', 1);
779
-define('BUILD_AMOUNT_WRONG'    , 2);
780
-define('BUILD_QUE_WRONG'       , 3);
781
-define('BUILD_QUE_UNIT_WRONG'  , 4);
782
-define('BUILD_INDESTRUCTABLE'  , 5);
783
-define('BUILD_NO_RESOURCES'    , 6);
784
-define('BUILD_NO_UNITS'        , 7);
785
-define('BUILD_UNIT_BUSY'       , 8);
786
-define('BUILD_QUE_FULL'        , 9);
787
-define('BUILD_SILO_FULL'       ,10);
788
-define('BUILD_MAX_REACHED'     ,11);
789
-define('BUILD_SECTORS_NONE'    ,12);
779
+define('BUILD_AMOUNT_WRONG', 2);
780
+define('BUILD_QUE_WRONG', 3);
781
+define('BUILD_QUE_UNIT_WRONG', 4);
782
+define('BUILD_INDESTRUCTABLE', 5);
783
+define('BUILD_NO_RESOURCES', 6);
784
+define('BUILD_NO_UNITS', 7);
785
+define('BUILD_UNIT_BUSY', 8);
786
+define('BUILD_QUE_FULL', 9);
787
+define('BUILD_SILO_FULL', 10);
788
+define('BUILD_MAX_REACHED', 11);
789
+define('BUILD_SECTORS_NONE', 12);
790 790
 define('BUILD_AUTOCONVERT_AVAILABLE', 13);
791 791
 
792 792
 
793 793
 // *** Que types
794 794
 define('QUE_STRUCTURES', 1);
795
-define('QUE_HANGAR'    , 4);
796
-define('QUE_RESEARCH'  , 7);
797
-define('QUE_MERCENARY' , 600); // UNIT_MERCENARIES
795
+define('QUE_HANGAR', 4);
796
+define('QUE_RESEARCH', 7);
797
+define('QUE_MERCENARY', 600); // UNIT_MERCENARIES
798 798
 // *** Subque types
799
-define('SUBQUE_PLANET'  , 1);
800
-define('SUBQUE_MOON'    , 3);
801
-define('SUBQUE_FLEET'   , 4);
802
-define('SUBQUE_DEFENSE' , 6);
799
+define('SUBQUE_PLANET', 1);
800
+define('SUBQUE_MOON', 3);
801
+define('SUBQUE_FLEET', 4);
802
+define('SUBQUE_DEFENSE', 6);
803 803
 define('SUBQUE_RESEARCH', 7);
804 804
 
805 805
 // *** Que items
806
-define('QI_UNIT_ID'   , 0);
807
-define('QI_AMOUNT'    , 1);
808
-define('QI_TIME'      , 2);
809
-define('QI_MODE'      , 3);
810
-define('QI_QUE_ID'    , 4);
811
-define('QI_QUE_TYPE'  , 4);
812
-define('QI_PLANET_ID' , 5);
806
+define('QI_UNIT_ID', 0);
807
+define('QI_AMOUNT', 1);
808
+define('QI_TIME', 2);
809
+define('QI_MODE', 3);
810
+define('QI_QUE_ID', 4);
811
+define('QI_QUE_TYPE', 4);
812
+define('QI_PLANET_ID', 5);
813 813
 
814 814
 
815 815
 // *** Units
816 816
 
817 817
 // *** Sort options
818
-define('SORT_ASCENDING' , 0);
818
+define('SORT_ASCENDING', 0);
819 819
 define('SORT_DESCENDING', 1);
820 820
 
821
-define('SORT_ID'             , 0);
822
-define('SORT_LOCATION'       , 1);
823
-define('SORT_NAME'           , 2);
824
-define('SORT_SIZE'           , 3);
825
-define('SORT_EMAIL'          , 4);
826
-define('SORT_IP'             , 5);
821
+define('SORT_ID', 0);
822
+define('SORT_LOCATION', 1);
823
+define('SORT_NAME', 2);
824
+define('SORT_SIZE', 3);
825
+define('SORT_EMAIL', 4);
826
+define('SORT_IP', 5);
827 827
 define('SORT_TIME_REGISTERED', 6);
828 828
 define('SORT_TIME_LAST_VISIT', 7);
829
-define('SORT_TIME_BAN_UNTIL' , 8);
830
-define('SORT_REFERRAL_COUNT' , 9);
831
-define('SORT_REFERRAL_DM'    , 10);
829
+define('SORT_TIME_BAN_UNTIL', 8);
830
+define('SORT_REFERRAL_COUNT', 9);
831
+define('SORT_REFERRAL_DM', 10);
832 832
 
833 833
 
834 834
 define('HULL_SIZE_TINY', 1);
@@ -971,10 +971,10 @@  discard block
 block discarded – undo
971 971
 
972 972
 // === Artifacts
973 973
 define('UNIT_ARTIFACTS', 1000);
974
-define('ART_LHC', 1001);      // Additional moon chance
975
-define('ART_RCD_SMALL', 1002);   // Rapid Colony Deployment - Set of buildings up to 10th level - 10/14/ 3/0 -   405 DM
976
-define('ART_RCD_MEDIUM', 1003);  // Rapid Colony Deployment - Set of buildings up to 15th level - 15/20/ 8/0 -  4704 DM
977
-define('ART_RCD_LARGE', 1004);   // Rapid Colony Deployment - Set of buildings up to 20th level - 20/25/10/1 - 39790 DM
974
+define('ART_LHC', 1001); // Additional moon chance
975
+define('ART_RCD_SMALL', 1002); // Rapid Colony Deployment - Set of buildings up to 10th level - 10/14/ 3/0 -   405 DM
976
+define('ART_RCD_MEDIUM', 1003); // Rapid Colony Deployment - Set of buildings up to 15th level - 15/20/ 8/0 -  4704 DM
977
+define('ART_RCD_LARGE', 1004); // Rapid Colony Deployment - Set of buildings up to 20th level - 20/25/10/1 - 39790 DM
978 978
 define('ART_HEURISTIC_CHIP', 1005); // Speed up research
979 979
 define('ART_NANO_BUILDER', 1006); // Speed up building
980 980
 define('ART_NANO_CONSTRUCTOR', 1007); // RESERVED Speed up hangar constructions
@@ -1047,21 +1047,21 @@  discard block
 block discarded – undo
1047 1047
 define('UNIT_AWARD_MEDAL_BLITZ_R0_PLACE1', 2201); // Блиц-сервер, участник 0-го раунда, 1-е место
1048 1048
 define('UNIT_AWARD_MEDAL_BLITZ_R0_PLACE2', 2202); // Блиц-сервер, участник 0-го раунда, 2-е место
1049 1049
 define('UNIT_AWARD_MEDAL_BLITZ_R0_PLACE3', 2203); // Блиц-сервер, участник 0-го раунда, 3-е место
1050
-define('UNIT_AWARD_MEDAL_2016_WOMEN_DAY_BEST', 2204);  // Медаль Лучшему Кавалеру за максимум потраченной ММ/максимум одаренных женщин Женщине от Мужчины во время ивента 8 марта 2016 года
1051
-define('UNIT_AWARD_MEDAL_2017_WOMEN_DAY_BEST', 2205);  // Медаль Лучшему Кавалеру за максимум потраченной ММ/максимум одаренных женщин Женщине от Мужчины во время ивента 8 марта 2017 года
1052
-define('UNIT_AWARD_MEDAL_2017_WOMEN_DAY_QUEEN', 2206);  // Медаль Королевы Весны за максимум полученной ММ/максимум полученных подарков от Мужчины во время ивента 8 марта 2017 года
1050
+define('UNIT_AWARD_MEDAL_2016_WOMEN_DAY_BEST', 2204); // Медаль Лучшему Кавалеру за максимум потраченной ММ/максимум одаренных женщин Женщине от Мужчины во время ивента 8 марта 2016 года
1051
+define('UNIT_AWARD_MEDAL_2017_WOMEN_DAY_BEST', 2205); // Медаль Лучшему Кавалеру за максимум потраченной ММ/максимум одаренных женщин Женщине от Мужчины во время ивента 8 марта 2017 года
1052
+define('UNIT_AWARD_MEDAL_2017_WOMEN_DAY_QUEEN', 2206); // Медаль Королевы Весны за максимум полученной ММ/максимум полученных подарков от Мужчины во время ивента 8 марта 2017 года
1053 1053
 
1054 1054
 define('UNIT_AWARD_MEMORY', 2300); // Памятные знаки за существование и участие - например "4 года в игре". "Был онлайн в новогоднюю ночь 2013". итд
1055
-define('UNIT_AWARD_MEMORY_IMMORTAL', 2301);  // Бессмертный
1056
-define('UNIT_AWARD_MEMORY_2015_WOMEN_DAY', 2302);  // Значек за подарок Женщине от Мужчины во время ивента 8 марта 2015 года
1055
+define('UNIT_AWARD_MEMORY_IMMORTAL', 2301); // Бессмертный
1056
+define('UNIT_AWARD_MEMORY_2015_WOMEN_DAY', 2302); // Значек за подарок Женщине от Мужчины во время ивента 8 марта 2015 года
1057 1057
 define('UNIT_AWARD_MEMORY_BLITZ_R0', 2303); // Блиц-сервер, участник 0-го раунда
1058 1058
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2015_SIMPLE', 2304); // День Рождения СН
1059 1059
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2015_BRONZE', 2305); // День Рождения СН
1060 1060
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2015_SILVER', 2306); // День Рождения СН
1061 1061
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2015_GOLD', 2307); // День Рождения СН
1062 1062
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2015_PLATINUM', 2308); // День Рождения СН
1063
-define('UNIT_AWARD_MEMORY_2016_WOMEN_DAY', 2309);  // Значек за подарок Женщине от Мужчины во время ивента 8 марта 2016 года
1064
-define('UNIT_AWARD_MEMORY_2017_WOMEN_DAY', 2310);  // Значек за подарок Женщине от Мужчины во время ивента 8 марта 2017 года
1063
+define('UNIT_AWARD_MEMORY_2016_WOMEN_DAY', 2309); // Значек за подарок Женщине от Мужчины во время ивента 8 марта 2016 года
1064
+define('UNIT_AWARD_MEMORY_2017_WOMEN_DAY', 2310); // Значек за подарок Женщине от Мужчины во время ивента 8 марта 2017 года
1065 1065
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2017_SIMPLE', 2311); // День Рождения СН - 2017
1066 1066
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2017_BRONZE', 2312); // День Рождения СН - 2017
1067 1067
 define('UNIT_AWARD_MEMORY_SUPER_BORN_2017_SILVER', 2313); // День Рождения СН - 2017
@@ -1181,7 +1181,7 @@  discard block
 block discarded – undo
1181 1181
 
1182 1182
 define('UNIT_NEXT', 4000); // !!! Next unit start on 4000 !!!
1183 1183
 
1184
-define('GROUP_PART',         800000);
1184
+define('GROUP_PART', 800000);
1185 1185
 // Зарезервировано для запчастей: 800.001 - 899.999
1186 1186
 // define('GROUP_PART_HULL',    801000); // Корпуса - 1000 штук
1187 1187
 // define('GROUP_PART_ARMOR',   802000); // Броня - 1000 штук
@@ -1495,32 +1495,32 @@  discard block
 block discarded – undo
1495 1495
 
1496 1496
 
1497 1497
 // define('NICK_ID',               -1);
1498
-define('NICK_HTML',              0);
1499
-
1500
-define('NICK_FIRST',             1);
1501
-define('NICK_RACE',           1000);
1502
-define('NICK_GENDER',         2000);
1503
-define('NICK_AWARD',          3000);
1504
-define('NICK_VACATION',       3500);
1505
-define('NICK_BIRTHSDAY',      4000);
1506
-define('NICK_PREMIUM',        5000);
1507
-define('NICK_AUTH_LEVEL',     6000);
1508
-
1509
-define('NICK_HIGHLIGHT',      6300);
1510
-define('NICK_CLASS',          6450);
1511
-
1512
-define('NICK_NICK_CLASS',     6600);
1513
-define('NICK_NICK',           7000);
1498
+define('NICK_HTML', 0);
1499
+
1500
+define('NICK_FIRST', 1);
1501
+define('NICK_RACE', 1000);
1502
+define('NICK_GENDER', 2000);
1503
+define('NICK_AWARD', 3000);
1504
+define('NICK_VACATION', 3500);
1505
+define('NICK_BIRTHSDAY', 4000);
1506
+define('NICK_PREMIUM', 5000);
1507
+define('NICK_AUTH_LEVEL', 6000);
1508
+
1509
+define('NICK_HIGHLIGHT', 6300);
1510
+define('NICK_CLASS', 6450);
1511
+
1512
+define('NICK_NICK_CLASS', 6600);
1513
+define('NICK_NICK', 7000);
1514 1514
 define('NICK_NICK_CLASS_END', 7300);
1515 1515
 
1516
-define('NICK_ALLY_CLASS',     7600);
1517
-define('NICK_ALLY',           8000);
1516
+define('NICK_ALLY_CLASS', 7600);
1517
+define('NICK_ALLY', 8000);
1518 1518
 define('NICK_ALLY_CLASS_END', 8300);
1519 1519
 
1520
-define('NICK_CLASS_END',      8450);
1521
-define('NICK_HIGHLIGHT_END',  8600);
1520
+define('NICK_CLASS_END', 8450);
1521
+define('NICK_HIGHLIGHT_END', 8600);
1522 1522
 
1523
-define('NICK_LAST',           9999);
1523
+define('NICK_LAST', 9999);
1524 1524
 
1525 1525
 // Настройки игрока
1526 1526
 define('PLAYER_OPTION_MENU_SORT', 1);
@@ -1620,8 +1620,8 @@  discard block
 block discarded – undo
1620 1620
 define('LOG_ONLIINE_AGGREGATE_PERIOD_MINUTE_10', 1);
1621 1621
 
1622 1622
 define('BLITZ_REGISTER_DISABLED', 0);
1623
-define('BLITZ_REGISTER_OPEN'    , 1);
1624
-define('BLITZ_REGISTER_CLOSED'  , 2);
1623
+define('BLITZ_REGISTER_OPEN', 1);
1624
+define('BLITZ_REGISTER_CLOSED', 2);
1625 1625
 define('BLITZ_REGISTER_SHOW_LOGIN', 3);
1626 1626
 define('BLITZ_REGISTER_DISCLOSURE_NAMES', 4);
1627 1627
 
Please login to merge, or discard this patch.
classes/DBAL/Schema.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -52,11 +52,11 @@  discard block
 block discarded – undo
52 52
 
53 53
     $prefix_length = strlen($this->db->db_prefix);
54 54
 
55
-    while($row = $this->db->db_fetch($query)) {
56
-      foreach($row as $table_name) {
55
+    while ($row = $this->db->db_fetch($query)) {
56
+      foreach ($row as $table_name) {
57 57
         $this->tablesAll[$table_name] = $table_name;
58 58
 
59
-        if(strpos($table_name, $this->db->db_prefix) === 0) {
59
+        if (strpos($table_name, $this->db->db_prefix) === 0) {
60 60
           $table_name_sn = substr($table_name, $prefix_length);
61 61
           $this->tablesSn[$table_name_sn] = $table_name_sn;
62 62
         }
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
    * @return \string[]
71 71
    */
72 72
   public function getAllTables() {
73
-    if(!isset($this->tablesAll)) {
73
+    if (!isset($this->tablesAll)) {
74 74
       $this->loadTableNamesFromDb();
75 75
     }
76 76
 
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
    * @return string[]
84 84
    */
85 85
   public function getSnTables() {
86
-    if(!isset($this->tablesSn)) {
86
+    if (!isset($this->tablesSn)) {
87 87
       $this->loadTableNamesFromDb();
88 88
     }
89 89
 
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
    * @return TableSchema
108 108
    */
109 109
   public function getTableSchema($tableName) {
110
-    if(empty($this->tableSchemas[$tableName])) {
110
+    if (empty($this->tableSchemas[$tableName])) {
111 111
       $this->tableSchemas[$tableName] = new TableSchema($tableName, $this);
112 112
     }
113 113
 
Please login to merge, or discard this patch.
classes/Core/Repository.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
    */
30 30
   protected $_repository;
31 31
 
32
- /**
32
+  /**
33 33
    * @var ContainerPlus $_oldRepo
34 34
    */
35 35
   protected $_oldRepo;
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -86,7 +86,7 @@
 block discarded – undo
86 86
 
87 87
   public function get($entityClass, $id) {
88 88
     $entityIndex = get_class($entityClass) . '\\' . $id;
89
-    if(!isset($this->_repository[$entityIndex])) {
89
+    if (!isset($this->_repository[$entityIndex])) {
90 90
 
91 91
     }
92 92
 
Please login to merge, or discard this patch.
classes/classConfig.php 1 patch
Spacing   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -71,9 +71,9 @@  discard block
 block discarded – undo
71 71
     'advGoogleLeftMenuCode'        => '(Place here code for banner)',
72 72
 
73 73
     // Alliance bonus calculations
74
-    'ali_bonus_algorithm'          => 0,  // Bonus calculation algorithm
74
+    'ali_bonus_algorithm'          => 0, // Bonus calculation algorithm
75 75
     'ali_bonus_brackets'           => 10, // Brackets count for ALI_BONUS_BY_RANK
76
-    'ali_bonus_brackets_divisor'   => 10,// Bonus divisor for ALI_BONUS_BY_RANK
76
+    'ali_bonus_brackets_divisor'   => 10, // Bonus divisor for ALI_BONUS_BY_RANK
77 77
     'ali_bonus_divisor'            => 10000000, // Rank divisor for ALI_BONUS_BY_POINTS
78 78
     'ali_bonus_members'            => 10, // Minumum alliace size to start using bonus
79 79
 
@@ -109,17 +109,17 @@  discard block
 block discarded – undo
109 109
     'deuterium_basic_income'       => 0,
110 110
     'eco_scale_storage'            => 1,
111 111
     'eco_stockman_fleet'           => '', // Black Market - Starting amount of s/h ship merchant to sell
112
-    'eco_stockman_fleet_populate'  => 1,  // Populate empty Stockman fleet with ships or not
112
+    'eco_stockman_fleet_populate'  => 1, // Populate empty Stockman fleet with ships or not
113 113
     'empire_mercenary_base_period' => PERIOD_MONTH, // Base
114 114
     'empire_mercenary_temporary'   => 0, // Temporary empire-wide mercenaries
115 115
     'energy_basic_income'          => 0,
116 116
 
117 117
     // Bashing protection settings
118
-    'fleet_bashing_attacks'        => 3,      // Max amount of attack per wave - 3 by default
119
-    'fleet_bashing_interval'       => 1800,   // Maximum interval between attacks when they still count as one wave - 30m by default
120
-    'fleet_bashing_scope'          => 86400,  // Interval on which bashing waves counts - 24h by default
121
-    'fleet_bashing_war_delay'      => 43200,  // Delay before start bashing after declaring war to alliance - 12h by default
122
-    'fleet_bashing_waves'          => 3,      // Max amount of waves per day - 3 by default
118
+    'fleet_bashing_attacks'        => 3, // Max amount of attack per wave - 3 by default
119
+    'fleet_bashing_interval'       => 1800, // Maximum interval between attacks when they still count as one wave - 30m by default
120
+    'fleet_bashing_scope'          => 86400, // Interval on which bashing waves counts - 24h by default
121
+    'fleet_bashing_war_delay'      => 43200, // Delay before start bashing after declaring war to alliance - 12h by default
122
+    'fleet_bashing_waves'          => 3, // Max amount of waves per day - 3 by default
123 123
 
124 124
     'Fleet_Cdr'   => 30,
125 125
     'fleet_speed' => 1,
@@ -127,8 +127,8 @@  discard block
 block discarded – undo
127 127
     'fleet_update_interval' => 4,
128 128
     'fleet_update_lock'     => '', // SQL time when lock was acquired
129 129
 
130
-    'game_adminEmail'       => 'root@localhost',    // Admin's email to show to users
131
-    'game_counter'          => 0,  // Does built-in page hit counter is on?
130
+    'game_adminEmail'       => 'root@localhost', // Admin's email to show to users
131
+    'game_counter'          => 0, // Does built-in page hit counter is on?
132 132
     // Defaults
133 133
     'game_default_language' => 'ru',
134 134
     'game_default_skin'     => 'skins/EpicBlue/',
@@ -142,14 +142,14 @@  discard block
 block discarded – undo
142 142
     'game_maxSystem'      => 199,
143 143
     'game_maxPlanet'      => 15,
144 144
     // Game global settings
145
-    'game_mode'           => 0,           // 0 - SuperNova, 1 - oGame
145
+    'game_mode'           => 0, // 0 - SuperNova, 1 - oGame
146 146
     'game_name'           => 'SuperNova', // Server name (would be on banners and on top of left menu)
147 147
 
148 148
     'game_news_actual'        => PERIOD_DAY_3, // How long announcement would be marked as "New". In seconds. Default - 3 days
149
-    'game_news_overview'      => 3,    // How much last news to show in Overview page
150
-    'game_news_overview_show' => PERIOD_WEEK_2,    // How long news will be shown in Overview page in seconds. Default - 2 weeks
149
+    'game_news_overview'      => 3, // How much last news to show in Overview page
150
+    'game_news_overview_show' => PERIOD_WEEK_2, // How long news will be shown in Overview page in seconds. Default - 2 weeks
151 151
     // Noob protection
152
-    'game_noob_factor'        => 5,    // Multiplier to divide "stronger" and "weaker" users
152
+    'game_noob_factor'        => 5, // Multiplier to divide "stronger" and "weaker" users
153 153
     'game_noob_points'        => 5000, // Below this point user threated as noob. 0 to disable
154 154
 
155 155
     'game_multiaccount_enabled' => 0, // 1 - allow interactions for players with same IP (multiaccounts)
@@ -203,8 +203,8 @@  discard block
 block discarded – undo
203 203
     'payment_currency_exchange_wmu' => 30,
204 204
     'payment_currency_exchange_wmz' => 1,
205 205
 
206
-    'payment_lot_price' => 1,     // Lot price in default currency
207
-    'payment_lot_size'  => 2500,  // Lot size. Also service as minimum amount of DM that could be bought with one transaction
206
+    'payment_lot_price' => 1, // Lot price in default currency
207
+    'payment_lot_size'  => 2500, // Lot size. Also service as minimum amount of DM that could be bought with one transaction
208 208
 
209 209
     'planet_teleport_cost'    => 50000, //
210 210
     'planet_teleport_timeout' => 86400, //
@@ -222,7 +222,7 @@  discard block
 block discarded – undo
222 222
     'resource_multiplier'     => 1,
223 223
 
224 224
     //Roleplay system
225
-    'rpg_bonus_divisor'       => 10,    // Amount of DM referral shoud get for partner have 1 DM bonus
225
+    'rpg_bonus_divisor'       => 10, // Amount of DM referral shoud get for partner have 1 DM bonus
226 226
     'rpg_bonus_minimum'       => 10000, // Minimum DM ammount for starting paying bonuses to affiliate
227 227
 
228 228
     // Black Market - General
Please login to merge, or discard this patch.
classes/db_mysql.php 1 patch
Spacing   +49 added lines, -49 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
   }
65 65
 
66 66
   public function schema() {
67
-    if(!isset(self::$schema)) {
67
+    if (!isset(self::$schema)) {
68 68
       self::$schema = new \DBAL\Schema($this);
69 69
     }
70 70
 
@@ -82,23 +82,23 @@  discard block
 block discarded – undo
82 82
   function sn_db_connect($external_db_settings = null) {
83 83
     $this->db_disconnect();
84 84
 
85
-    if(!empty($external_db_settings) && is_array($external_db_settings)) {
85
+    if (!empty($external_db_settings) && is_array($external_db_settings)) {
86 86
       $this->dbsettings = $external_db_settings;
87 87
     }
88 88
 
89
-    if(empty($this->dbsettings)) {
89
+    if (empty($this->dbsettings)) {
90 90
       $this->load_db_settings();
91 91
     }
92 92
 
93 93
     // TODO - фатальные (?) ошибки на каждом шагу. Хотя - скорее Эксепшны
94
-    if(!empty($this->dbsettings)) {
94
+    if (!empty($this->dbsettings)) {
95 95
       $driver_name = empty($this->dbsettings['sn_driver']) ? 'db_mysql_v5' : $this->dbsettings['sn_driver'];
96 96
       $this->driver = new $driver_name();
97 97
       $this->db_prefix = $this->dbsettings['prefix'];
98 98
 
99 99
       $this->connected = $this->connected || $this->driver_connect();
100 100
 
101
-      if($this->connected && empty($this->schema()->getSnTables())) {
101
+      if ($this->connected && empty($this->schema()->getSnTables())) {
102 102
         die('DB error - cannot find any table. Halting...');
103 103
       }
104 104
     } else {
@@ -111,11 +111,11 @@  discard block
 block discarded – undo
111 111
   function driver_connect() {
112 112
     global $debug;
113 113
 
114
-    if(!is_object($this->driver)) {
114
+    if (!is_object($this->driver)) {
115 115
       $debug->error_fatal('DB Error - No driver for MySQL found!');
116 116
     }
117 117
 
118
-    if(!method_exists($this->driver, 'mysql_connect')) {
118
+    if (!method_exists($this->driver, 'mysql_connect')) {
119 119
       $debug->error_fatal('DB Error - WRONG MySQL driver!');
120 120
     }
121 121
 
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
   }
124 124
 
125 125
   function db_disconnect() {
126
-    if($this->connected) {
126
+    if ($this->connected) {
127 127
       $this->connected = !$this->driver_disconnect();
128 128
       $this->connected = false;
129 129
     }
@@ -134,11 +134,11 @@  discard block
 block discarded – undo
134 134
   function doquery($query, $table = '', $fetch = false, $skip_query_check = false) {
135 135
     global $numqueries, $debug, $sn_cache, $config;
136 136
 
137
-    if(!is_string($table)) {
137
+    if (!is_string($table)) {
138 138
       $fetch = $table;
139 139
     }
140 140
 
141
-    if(!$this->connected) {
141
+    if (!$this->connected) {
142 142
       $this->sn_db_connect();
143 143
     }
144 144
 
@@ -147,30 +147,30 @@  discard block
 block discarded – undo
147 147
     $skip_query_check or $this->security_query_check_bad_words($query);
148 148
 
149 149
     $sql = $query;
150
-    if(strpos($sql, '{{') !== false) {
151
-      foreach($this->schema()->getSnTables() as $tableName) {
150
+    if (strpos($sql, '{{') !== false) {
151
+      foreach ($this->schema()->getSnTables() as $tableName) {
152 152
         $sql = str_replace("{{{$tableName}}}", $this->db_prefix . $tableName, $sql);
153 153
       }
154 154
     }
155 155
 
156
-    if($config->debug) {
156
+    if ($config->debug) {
157 157
       $numqueries++;
158 158
       $arr = debug_backtrace();
159
-      $file = end(explode('/',$arr[0]['file']));
159
+      $file = end(explode('/', $arr[0]['file']));
160 160
       $line = $arr[0]['line'];
161 161
       $debug->add("<tr><th>Query $numqueries: </th><th>$query</th><th>$file($line)</th><th>$table</th><th>$fetch</th></tr>");
162 162
     }
163 163
 
164
-    if(defined('DEBUG_SQL_COMMENT')) {
164
+    if (defined('DEBUG_SQL_COMMENT')) {
165 165
       $backtrace = debug_backtrace();
166 166
       $sql_comment = $debug->compact_backtrace($backtrace, defined('DEBUG_SQL_COMMENT_LONG'));
167 167
 
168 168
       $sql_commented = '/* ' . implode("<br />", $sql_comment) . '<br /> */ ' . preg_replace("/\s+/", ' ', $sql);
169
-      if(defined('DEBUG_SQL_ONLINE')) {
169
+      if (defined('DEBUG_SQL_ONLINE')) {
170 170
         $debug->warning($sql_commented, 'SQL Debug', LOG_DEBUG_SQL);
171 171
       }
172 172
 
173
-      if(defined('DEBUG_SQL_ERROR')) {
173
+      if (defined('DEBUG_SQL_ERROR')) {
174 174
         array_unshift($sql_comment, preg_replace("/\s+/", ' ', $sql));
175 175
         $debug->add_to_array($sql_comment);
176 176
         // $debug->add_to_array($sql_comment . preg_replace("/\s+/", ' ', $sql));
@@ -178,7 +178,7 @@  discard block
 block discarded – undo
178 178
       $sql = $sql_commented;
179 179
     }
180 180
 
181
-    $sqlquery = $this->db_sql_query($sql) or $debug->error(db_error()."<br />$sql<br />",'SQL Error');
181
+    $sqlquery = $this->db_sql_query($sql) or $debug->error(db_error() . "<br />$sql<br />", 'SQL Error');
182 182
 
183 183
     return $fetch ? $this->db_fetch($sqlquery) : $sqlquery;
184 184
   }
@@ -197,16 +197,16 @@  discard block
 block discarded – undo
197 197
     // TODO Заменить это на новый логгер
198 198
     global $config, $is_watching, $user, $debug;
199 199
 
200
-    if(!$is_watching && $config->game_watchlist_array && in_array($user['id'], $config->game_watchlist_array))
200
+    if (!$is_watching && $config->game_watchlist_array && in_array($user['id'], $config->game_watchlist_array))
201 201
     {
202
-      if(!preg_match('/^(select|commit|rollback|start transaction)/i', $query)) {
202
+      if (!preg_match('/^(select|commit|rollback|start transaction)/i', $query)) {
203 203
         $is_watching = true;
204 204
         $msg = "\$query = \"{$query}\"\n\r";
205
-        if(!empty($_POST)) {
206
-          $msg .= "\n\r" . dump($_POST,'$_POST');
205
+        if (!empty($_POST)) {
206
+          $msg .= "\n\r" . dump($_POST, '$_POST');
207 207
         }
208
-        if(!empty($_GET)) {
209
-          $msg .= "\n\r" . dump($_GET,'$_GET');
208
+        if (!empty($_GET)) {
209
+          $msg .= "\n\r" . dump($_GET, '$_GET');
210 210
         }
211 211
         $debug->warning($msg, "Watching user {$user['id']}", 399, array('base_dump' => true));
212 212
         $is_watching = false;
@@ -218,7 +218,7 @@  discard block
 block discarded – undo
218 218
   function security_query_check_bad_words($query) {
219 219
     global $user, $dm_change_legit, $mm_change_legit;
220 220
 
221
-    switch(true) {
221
+    switch (true) {
222 222
       case stripos($query, 'RUNCATE TABL') != false:
223 223
       case stripos($query, 'ROP TABL') != false:
224 224
       case stripos($query, 'ENAME TABL') != false:
@@ -229,33 +229,33 @@  discard block
 block discarded – undo
229 229
       case stripos($query, 'RPG_POINTS') != false && stripos(trim($query), 'UPDATE ') === 0 && !$dm_change_legit:
230 230
       case stripos($query, 'METAMATTER') != false && stripos(trim($query), 'UPDATE ') === 0 && !$mm_change_legit:
231 231
       case stripos($query, 'AUTHLEVEL') != false && $user['authlevel'] < 3 && stripos($query, 'SELECT') !== 0:
232
-        $report  = "Hacking attempt (".date("d.m.Y H:i:s")." - [".time()."]):\n";
232
+        $report  = "Hacking attempt (" . date("d.m.Y H:i:s") . " - [" . time() . "]):\n";
233 233
         $report .= ">Database Inforamation\n";
234
-        $report .= "\tID - ".$user['id']."\n";
235
-        $report .= "\tUser - ".$user['username']."\n";
236
-        $report .= "\tAuth level - ".$user['authlevel']."\n";
237
-        $report .= "\tAdmin Notes - ".$user['adminNotes']."\n";
238
-        $report .= "\tCurrent Planet - ".$user['current_planet']."\n";
239
-        $report .= "\tUser IP - ".$user['user_lastip']."\n";
240
-        $report .= "\tUser IP at Reg - ".$user['ip_at_reg']."\n";
241
-        $report .= "\tUser Agent- ".$_SERVER['HTTP_USER_AGENT']."\n";
242
-        $report .= "\tCurrent Page - ".$user['current_page']."\n";
243
-        $report .= "\tRegister Time - ".$user['register_time']."\n";
234
+        $report .= "\tID - " . $user['id'] . "\n";
235
+        $report .= "\tUser - " . $user['username'] . "\n";
236
+        $report .= "\tAuth level - " . $user['authlevel'] . "\n";
237
+        $report .= "\tAdmin Notes - " . $user['adminNotes'] . "\n";
238
+        $report .= "\tCurrent Planet - " . $user['current_planet'] . "\n";
239
+        $report .= "\tUser IP - " . $user['user_lastip'] . "\n";
240
+        $report .= "\tUser IP at Reg - " . $user['ip_at_reg'] . "\n";
241
+        $report .= "\tUser Agent- " . $_SERVER['HTTP_USER_AGENT'] . "\n";
242
+        $report .= "\tCurrent Page - " . $user['current_page'] . "\n";
243
+        $report .= "\tRegister Time - " . $user['register_time'] . "\n";
244 244
         $report .= "\n";
245 245
 
246 246
         $report .= ">Query Information\n";
247
-        $report .= "\tQuery - ".$query."\n";
247
+        $report .= "\tQuery - " . $query . "\n";
248 248
         $report .= "\n";
249 249
 
250 250
         $report .= ">\$_SERVER Information\n";
251
-        $report .= "\tIP - ".$_SERVER['REMOTE_ADDR']."\n";
252
-        $report .= "\tHost Name - ".$_SERVER['HTTP_HOST']."\n";
253
-        $report .= "\tUser Agent - ".$_SERVER['HTTP_USER_AGENT']."\n";
254
-        $report .= "\tRequest Method - ".$_SERVER['REQUEST_METHOD']."\n";
255
-        $report .= "\tCame From - ".$_SERVER['HTTP_REFERER']."\n";
256
-        $report .= "\tPage is - ".$_SERVER['SCRIPT_NAME']."\n";
257
-        $report .= "\tUses Port - ".$_SERVER['REMOTE_PORT']."\n";
258
-        $report .= "\tServer Protocol - ".$_SERVER['SERVER_PROTOCOL']."\n";
251
+        $report .= "\tIP - " . $_SERVER['REMOTE_ADDR'] . "\n";
252
+        $report .= "\tHost Name - " . $_SERVER['HTTP_HOST'] . "\n";
253
+        $report .= "\tUser Agent - " . $_SERVER['HTTP_USER_AGENT'] . "\n";
254
+        $report .= "\tRequest Method - " . $_SERVER['REQUEST_METHOD'] . "\n";
255
+        $report .= "\tCame From - " . $_SERVER['HTTP_REFERER'] . "\n";
256
+        $report .= "\tPage is - " . $_SERVER['SCRIPT_NAME'] . "\n";
257
+        $report .= "\tUses Port - " . $_SERVER['REMOTE_PORT'] . "\n";
258
+        $report .= "\tServer Protocol - " . $_SERVER['SERVER_PROTOCOL'] . "\n";
259 259
 
260 260
         $report .= "\n--------------------------------------------------------------------------------------------------\n";
261 261
 
@@ -286,7 +286,7 @@  discard block
 block discarded – undo
286 286
 
287 287
     $prefixedTableName_safe = $this->db_escape($this->db_prefix . $tableName_unsafe);
288 288
     $q1 = $this->db_sql_query("SHOW FULL COLUMNS FROM `{$prefixedTableName_safe}`;");
289
-    while($r1 = db_fetch($q1)) {
289
+    while ($r1 = db_fetch($q1)) {
290 290
       $result[$r1['Field']] = $r1;
291 291
     }
292 292
     return $result;
@@ -302,7 +302,7 @@  discard block
 block discarded – undo
302 302
 
303 303
     $prefixedTableName_safe = $this->db_escape($this->db_prefix . $tableName_unsafe);
304 304
     $q1 = $this->db_sql_query("SHOW INDEX FROM {$prefixedTableName_safe};");
305
-    while($r1 = db_fetch($q1)) {
305
+    while ($r1 = db_fetch($q1)) {
306 306
       $indexName = $r1['Key_name'];
307 307
 
308 308
       $result[$indexName]['name'] = $r1['Key_name'];
@@ -327,8 +327,8 @@  discard block
 block discarded – undo
327 327
 
328 328
     $prefixedTableName_safe = $this->db_escape($this->db_prefix . $tableName_unsafe);
329 329
 
330
-    $q1 = $this->db_sql_query("SELECT * FROM `information_schema`.`KEY_COLUMN_USAGE` WHERE `TABLE_SCHEMA` = '" . db_escape(classSupernova::$db_name). "' AND `TABLE_NAME` = '{$prefixedTableName_safe}' AND `REFERENCED_TABLE_NAME` IS NOT NULL;");
331
-    while($r1 = db_fetch($q1)) {
330
+    $q1 = $this->db_sql_query("SELECT * FROM `information_schema`.`KEY_COLUMN_USAGE` WHERE `TABLE_SCHEMA` = '" . db_escape(classSupernova::$db_name) . "' AND `TABLE_NAME` = '{$prefixedTableName_safe}' AND `REFERENCED_TABLE_NAME` IS NOT NULL;");
331
+    while ($r1 = db_fetch($q1)) {
332 332
       $indexName = $r1['CONSTRAINT_NAME'];
333 333
 
334 334
       $table_referenced = str_replace($this->db_prefix, '', $r1['REFERENCED_TABLE_NAME']);
Please login to merge, or discard this patch.
classes/Common/GlobalContainer.php 1 patch
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -70,66 +70,66 @@
 block discarded – undo
70 70
 
71 71
     // Services --------------------------------------------------------------------------------------------------------
72 72
     // Default db
73
-    $gc->db = function (GlobalContainer $c) {
73
+    $gc->db = function(GlobalContainer $c) {
74 74
       classSupernova::$db = new \db_mysql($c);
75 75
 
76 76
       return classSupernova::$db;
77 77
     };
78 78
 
79
-    $gc->debug = function (GlobalContainer $c) {
79
+    $gc->debug = function(GlobalContainer $c) {
80 80
       return new \debug();
81 81
     };
82 82
 
83
-    $gc->cache = function (GlobalContainer $gc) {
83
+    $gc->cache = function(GlobalContainer $gc) {
84 84
       return new \classCache($gc->cachePrefix);
85 85
     };
86 86
 
87
-    $gc->config = function (GlobalContainer $gc) {
87
+    $gc->config = function(GlobalContainer $gc) {
88 88
       return new \classConfig($gc->cachePrefix);
89 89
     };
90 90
 
91 91
 
92
-    $gc->repository = function (GlobalContainer $gc) {
92
+    $gc->repository = function(GlobalContainer $gc) {
93 93
       return new \Core\Repository($gc);
94 94
     };
95 95
 
96
-    $gc->storage = function (GlobalContainer $gc) {
96
+    $gc->storage = function(GlobalContainer $gc) {
97 97
       return new \Storage($gc);
98 98
     };
99 99
 
100
-    $gc->design = function (GlobalContainer $gc) {
100
+    $gc->design = function(GlobalContainer $gc) {
101 101
       return new \Design($gc);
102 102
     };
103 103
 
104
-    $gc->bbCodeParser = function (GlobalContainer $gc) {
104
+    $gc->bbCodeParser = function(GlobalContainer $gc) {
105 105
       return new \BBCodeParser($gc);
106 106
     };
107 107
 
108
-    $gc->fleetDispatcher = function (GlobalContainer $gc) {
108
+    $gc->fleetDispatcher = function(GlobalContainer $gc) {
109 109
       return new \FleetDispatcher($gc);
110 110
     };
111 111
 
112
-    $gc->watchdog = function (GlobalContainer $gc) {
112
+    $gc->watchdog = function(GlobalContainer $gc) {
113 113
       return new Watchdog($gc);
114 114
     };
115 115
 
116
-    $gc->eventBus = function (GlobalContainer $gc) {
116
+    $gc->eventBus = function(GlobalContainer $gc) {
117 117
       return new EventBus($gc);
118 118
     };
119 119
 
120 120
     // Dummy objects ---------------------------------------------------------------------------------------------------
121
-    $gc->theUser = function (GlobalContainer $gc) {
121
+    $gc->theUser = function(GlobalContainer $gc) {
122 122
       return new \TheUser($gc);
123 123
     };
124 124
 
125 125
 
126 126
     // Models ----------------------------------------------------------------------------------------------------------
127 127
     $gc->skinEntityClass = 'SkinV2';
128
-    $gc->skinModel = function (GlobalContainer $gc) {
128
+    $gc->skinModel = function(GlobalContainer $gc) {
129 129
       return new \SkinModel($gc);
130 130
     };
131 131
 
132
-    $gc->textModel = function (GlobalContainer $gc) {
132
+    $gc->textModel = function(GlobalContainer $gc) {
133 133
       return new \TextModel($gc);
134 134
     };
135 135
 
Please login to merge, or discard this patch.