Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Failed Conditions
Pull Request — master (#1061)
by
unknown
26:57 queued 22:10
created
src/admin/Default/1.6/game_edit_processing.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,8 +2,7 @@
 block discarded – undo
2 2
 
3 3
 // Get the dates ("|" sets hr/min/sec to 0)
4 4
 $join = DateTime::createFromFormat('d/m/Y|', Request::get('game_join'));
5
-$start = empty(Request::get('game_start')) ? $join :
6
-         DateTime::createFromFormat('d/m/Y|', Request::get('game_start'));
5
+$start = empty(Request::get('game_start')) ? $join : DateTime::createFromFormat('d/m/Y|', Request::get('game_start'));
7 6
 $end = DateTime::createFromFormat('d/m/Y|', Request::get('game_end'));
8 7
 
9 8
 $game = SmrGame::getGame($var['game_id']);
Please login to merge, or discard this patch.
src/engine/Default/hall_of_fame_player_detail.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,13 +20,13 @@
 block discarded – undo
20 20
 const USER_SCORE_NAME = 'User Score';
21 21
 $hofTypes = array(DONATION_NAME=>true, USER_SCORE_NAME=>true);
22 22
 while ($db->nextRecord()) {
23
-	$hof =& $hofTypes;
23
+	$hof = & $hofTypes;
24 24
 	$typeList = explode(':', $db->getField('type'));
25 25
 	foreach ($typeList as $type) {
26 26
 		if (!isset($hof[$type])) {
27 27
 			$hof[$type] = array();
28 28
 		}
29
-		$hof =& $hof[$type];
29
+		$hof = & $hof[$type];
30 30
 	}
31 31
 	$hof = true;
32 32
 }
Please login to merge, or discard this patch.
src/engine/Default/chat_sharing.php 1 patch
Spacing   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -19,8 +19,7 @@  discard block
 block discarded – undo
19 19
 	$shareFrom[$fromAccountId] = array(
20 20
 		'Player ID'   => $otherPlayer == null ? '-' : $otherPlayer->getPlayerID(),
21 21
 		'Player Name' => $otherPlayer == null ?
22
-		                 '<b>Account</b>: ' . SmrAccount::getAccount($fromAccountId)->getHofDisplayName() :
23
-		                 $otherPlayer->getDisplayName(),
22
+		                 '<b>Account</b>: ' . SmrAccount::getAccount($fromAccountId)->getHofDisplayName() : $otherPlayer->getDisplayName(),
24 23
 		'All Games'   => $gameId == 0 ? '<span class="green">YES</span>' : '<span class="red">NO</span>',
25 24
 		'Game ID'     => $gameId,
26 25
 	);
@@ -40,8 +39,7 @@  discard block
 block discarded – undo
40 39
 	$shareTo[$toAccountId] = array(
41 40
 		'Player ID'   => $otherPlayer == null ? '-' : $otherPlayer->getPlayerID(),
42 41
 		'Player Name' => $otherPlayer == null ?
43
-		                 '<b>Account</b>: ' . SmrAccount::getAccount($toAccountId)->getHofDisplayName() :
44
-		                 $otherPlayer->getDisplayName(),
42
+		                 '<b>Account</b>: ' . SmrAccount::getAccount($toAccountId)->getHofDisplayName() : $otherPlayer->getDisplayName(),
45 43
 		'All Games'   => $gameId == 0 ? '<span class="green">YES</span>' : '<span class="red">NO</span>',
46 44
 		'Game ID'     => $gameId,
47 45
 	);
Please login to merge, or discard this patch.
src/engine/Default/hall_of_fame_new.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,13 +20,13 @@
 block discarded – undo
20 20
 const USER_SCORE_NAME = 'User Score';
21 21
 $hofTypes = array(DONATION_NAME=>true, USER_SCORE_NAME=>true);
22 22
 while ($db->nextRecord()) {
23
-	$hof =& $hofTypes;
23
+	$hof = & $hofTypes;
24 24
 	$typeList = explode(':', $db->getField('type'));
25 25
 	foreach ($typeList as $type) {
26 26
 		if (!isset($hof[$type])) {
27 27
 			$hof[$type] = array();
28 28
 		}
29
-		$hof =& $hof[$type];
29
+		$hof = & $hof[$type];
30 30
 	}
31 31
 	$hof = true;
32 32
 }
Please login to merge, or discard this patch.
src/tools/discord/GameLink.class.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -3,10 +3,10 @@
 block discarded – undo
3 3
 // Holds information linking the received message and the game data
4 4
 class GameLink
5 5
 {
6
-	public $valid = false;  // identifies if the message is linked to game data
7
-	public $account;        // SmrAccount instance
8
-	public $alliance;       // SmrAlliance instance
9
-	public $player;         // SmrPlayer instance
6
+	public $valid = false; // identifies if the message is linked to game data
7
+	public $account; // SmrAccount instance
8
+	public $alliance; // SmrAlliance instance
9
+	public $player; // SmrPlayer instance
10 10
 
11 11
 	// $author can be either Discord\Parts\User\{User,Member}
12 12
 	function __construct(Discord\Parts\Channel\Channel $channel, $author) {
Please login to merge, or discard this patch.
src/admin/Default/1.6/game_create_processing.php 1 patch
Spacing   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -18,8 +18,7 @@
 block discarded – undo
18 18
 if ($join === false) {
19 19
 	create_error('Join Date is not valid!');
20 20
 }
21
-$start = empty(Request::get('game_start')) ? $join :
22
-         DateTime::createFromFormat('d/m/Y|', Request::get('game_start'));
21
+$start = empty(Request::get('game_start')) ? $join : DateTime::createFromFormat('d/m/Y|', Request::get('game_start'));
23 22
 if ($start === false) {
24 23
 	create_error('Start Date is not valid!');
25 24
 }
Please login to merge, or discard this patch.
src/lib/Default/AbstractSmrAccount.class.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -374,13 +374,13 @@
 block discarded – undo
374 374
 			$this->db->query('SELECT type,sum(amount) as amount FROM player_hof WHERE ' . $this->SQL . ' AND game_id IN (SELECT game_id FROM game WHERE ignore_stats = \'FALSE\') GROUP BY type');
375 375
 			$this->HOF = array();
376 376
 			while ($this->db->nextRecord()) {
377
-				$hof =& $this->HOF;
377
+				$hof = & $this->HOF;
378 378
 				$typeList = explode(':', $this->db->getField('type'));
379 379
 				foreach ($typeList as $type) {
380 380
 					if (!isset($hof[$type])) {
381 381
 						$hof[$type] = array();
382 382
 					}
383
-					$hof =& $hof[$type];
383
+					$hof = & $hof[$type];
384 384
 				}
385 385
 				$hof = $this->db->getFloat('amount');
386 386
 			}
Please login to merge, or discard this patch.
src/lib/Default/SmrPlanetType.class.php 1 patch
Spacing   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -79,12 +79,12 @@  discard block
 block discarded – undo
79 79
 			'exp_gain' => 540,
80 80
 		],
81 81
 	];
82
-	public function name()         { return "Terran Planet"; }
83
-	public function imageLink()    { return "images/planet1.png"; }
84
-	public function description()  { return "A lush world, with forests, seas, sweeping meadows, and indigenous lifeforms."; }
82
+	public function name() { return "Terran Planet"; }
83
+	public function imageLink() { return "images/planet1.png"; }
84
+	public function description() { return "A lush world, with forests, seas, sweeping meadows, and indigenous lifeforms."; }
85 85
 	public function maxAttackers() { return 10; }
86
-	public function maxLanded()    { return self::MAX_LANDED_UNLIMITED; }
87
-	public function menuOptions()  { return self::DEFAULT_MENU_OPTIONS; }
86
+	public function maxLanded() { return self::MAX_LANDED_UNLIMITED; }
87
+	public function menuOptions() { return self::DEFAULT_MENU_OPTIONS; }
88 88
 }
89 89
 
90 90
 class AridPlanet extends SmrPlanetType {
@@ -108,12 +108,12 @@  discard block
 block discarded – undo
108 108
 			'exp_gain' => 180,
109 109
 		],
110 110
 	];
111
-	public function name()         { return "Arid Planet"; }
112
-	public function imageLink()    { return "images/planet2.png"; }
113
-	public function description()  { return "A world mostly devoid of surface water, but capable of supporting life."; }
111
+	public function name() { return "Arid Planet"; }
112
+	public function imageLink() { return "images/planet2.png"; }
113
+	public function description() { return "A world mostly devoid of surface water, but capable of supporting life."; }
114 114
 	public function maxAttackers() { return 5; }
115
-	public function maxLanded()    { return 5; }
116
-	public function menuOptions()  { return ['CONSTRUCTION', 'DEFENSE', 'STOCKPILE', 'OWNERSHIP']; }
115
+	public function maxLanded() { return 5; }
116
+	public function menuOptions() { return ['CONSTRUCTION', 'DEFENSE', 'STOCKPILE', 'OWNERSHIP']; }
117 117
 }
118 118
 
119 119
 class DwarfPlanet extends SmrPlanetType {
@@ -137,12 +137,12 @@  discard block
 block discarded – undo
137 137
 			'exp_gain' => 540,
138 138
 		],
139 139
 	];
140
-	public function name()         { return "Dwarf Planet"; }
141
-	public function imageLink()    { return "images/planet3.png"; }
142
-	public function description()  { return "A smaller than usual planet, with no native life present."; }
140
+	public function name() { return "Dwarf Planet"; }
141
+	public function imageLink() { return "images/planet3.png"; }
142
+	public function description() { return "A smaller than usual planet, with no native life present."; }
143 143
 	public function maxAttackers() { return 5; }
144
-	public function maxLanded()    { return self::MAX_LANDED_UNLIMITED; }
145
-	public function menuOptions()  { return self::DEFAULT_MENU_OPTIONS; }
144
+	public function maxLanded() { return self::MAX_LANDED_UNLIMITED; }
145
+	public function menuOptions() { return self::DEFAULT_MENU_OPTIONS; }
146 146
 }
147 147
 
148 148
 class ProtoPlanet extends SmrPlanetType {
@@ -178,12 +178,12 @@  discard block
 block discarded – undo
178 178
 			'exp_gain' => 540,
179 179
 		],
180 180
 	];
181
-	public function name()         { return "Protoplanet"; }
182
-	public function imageLink()    { return "images/planet5.png"; }
183
-	public function description()  { return "A developing planet, not yet able to support the infrastructure of advanced technologies."; }
181
+	public function name() { return "Protoplanet"; }
182
+	public function imageLink() { return "images/planet5.png"; }
183
+	public function description() { return "A developing planet, not yet able to support the infrastructure of advanced technologies."; }
184 184
 	public function maxAttackers() { return 5; }
185
-	public function maxLanded()    { return 5; }
186
-	public function menuOptions()  { return self::DEFAULT_MENU_OPTIONS; }
185
+	public function maxLanded() { return 5; }
186
+	public function menuOptions() { return self::DEFAULT_MENU_OPTIONS; }
187 187
 }
188 188
 
189 189
 class DefenseWorld extends SmrPlanetType {
@@ -213,10 +213,10 @@  discard block
 block discarded – undo
213 213
 			'exp_gain' => 9,
214 214
 		],
215 215
 	];
216
-	public function name()         { return "Defense World"; }
217
-	public function imageLink()    { return "images/planet4.png"; }
218
-	public function description()  { return "A fully armed and operational battle station loaded with excessive firepower."; }
216
+	public function name() { return "Defense World"; }
217
+	public function imageLink() { return "images/planet4.png"; }
218
+	public function description() { return "A fully armed and operational battle station loaded with excessive firepower."; }
219 219
 	public function maxAttackers() { return 10; }
220
-	public function maxLanded()    { return self::MAX_LANDED_UNLIMITED; }
221
-	public function menuOptions()  { return self::DEFAULT_MENU_OPTIONS; }
220
+	public function maxLanded() { return self::MAX_LANDED_UNLIMITED; }
221
+	public function menuOptions() { return self::DEFAULT_MENU_OPTIONS; }
222 222
 }
Please login to merge, or discard this patch.
src/lib/Default/AbstractSmrPlayer.class.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -1711,7 +1711,7 @@  discard block
 block discarded – undo
1711 1711
 			create_error('The saved sector must be in the box!');
1712 1712
 		}
1713 1713
 
1714
-		$storedDestinations =& $this->getStoredDestinations();
1714
+		$storedDestinations = & $this->getStoredDestinations();
1715 1715
 		foreach ($storedDestinations as &$sd) {
1716 1716
 			if ($sd['SectorID'] == $sectorID) {
1717 1717
 				$sd['OffsetTop'] = $offsetTop;
@@ -2034,13 +2034,13 @@  discard block
 block discarded – undo
2034 2034
 			$this->db->query('SELECT type,amount FROM player_hof WHERE ' . $this->SQL);
2035 2035
 			$this->HOF = array();
2036 2036
 			while ($this->db->nextRecord()) {
2037
-				$hof =& $this->HOF;
2037
+				$hof = & $this->HOF;
2038 2038
 				$typeList = explode(':', $this->db->getField('type'));
2039 2039
 				foreach ($typeList as $type) {
2040 2040
 					if (!isset($hof[$type])) {
2041 2041
 						$hof[$type] = array();
2042 2042
 					}
2043
-					$hof =& $hof[$type];
2043
+					$hof = & $hof[$type];
2044 2044
 				}
2045 2045
 				$hof = $this->db->getFloat('amount');
2046 2046
 			}
@@ -2119,8 +2119,8 @@  discard block
 block discarded – undo
2119 2119
 		}
2120 2120
 		self::$HOFVis[$hofType] = $visibility;
2121 2121
 
2122
-		$hof =& $this->HOF;
2123
-		$hofChanged =& $this->hasHOFChanged;
2122
+		$hof = & $this->HOF;
2123
+		$hofChanged = & $this->hasHOFChanged;
2124 2124
 		$new = false;
2125 2125
 		foreach ($typeList as $type) {
2126 2126
 			if (!isset($hofChanged[$type])) {
@@ -2130,8 +2130,8 @@  discard block
 block discarded – undo
2130 2130
 				$hof[$type] = array();
2131 2131
 				$new = true;
2132 2132
 			}
2133
-			$hof =& $hof[$type];
2134
-			$hofChanged =& $hofChanged[$type];
2133
+			$hof = & $hof[$type];
2134
+			$hofChanged = & $hofChanged[$type];
2135 2135
 		}
2136 2136
 		if ($hofChanged == null) {
2137 2137
 			$hofChanged = self::HOF_CHANGED;
@@ -2780,7 +2780,7 @@  discard block
 block discarded – undo
2780 2780
 			'Starting Sector' => $this->getSectorID()
2781 2781
 		);
2782 2782
 
2783
-		$this->missions[$missionID] =& $mission;
2783
+		$this->missions[$missionID] = & $mission;
2784 2784
 		$this->setupMissionStep($missionID);
2785 2785
 		$this->rebuildMission($missionID);
2786 2786
 
@@ -2830,7 +2830,7 @@  discard block
 block discarded – undo
2830 2830
 
2831 2831
 	public function claimMissionReward($missionID) {
2832 2832
 		$this->getMissions();
2833
-		$mission =& $this->missions[$missionID];
2833
+		$mission = & $this->missions[$missionID];
2834 2834
 		if ($mission === false) {
2835 2835
 			throw new Exception('Unknown mission: ' . $missionID);
2836 2836
 		}
Please login to merge, or discard this patch.