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

Passed
Push — dependabot/composer/phpstan/ph... ( 1f7448...24894e )
by
unknown
07:10 queued 03:25
created
src/engine/Default/bar_gambling_processing.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
 
47 47
 function check_for_win(Smr\Blackjack\Hand $dealerHand, Smr\Blackjack\Hand $playerHand): string {
48 48
 	//does the player win
49
-	return match (true) {
49
+	return match(true) {
50 50
 		$playerHand->hasBusted() => 'no',
51 51
 		$playerHand->hasBlackjack() => 'bj',
52 52
 		$playerHand->getValue() == $dealerHand->getValue() => 'tie',
Please login to merge, or discard this patch.
src/lib/Smr/SocialLogin/SocialLogin.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@
 block discarded – undo
23 23
 	 * Returns a SocialLogin class of the given derived type.
24 24
 	 */
25 25
 	public static function get(string $loginType): self {
26
-		return match ($loginType) {
26
+		return match($loginType) {
27 27
 			Facebook::getLoginType() => new Facebook(),
28 28
 			Twitter::getLoginType() => new Twitter(),
29 29
 			Google::getLoginType() => new Google(),
Please login to merge, or discard this patch.
src/lib/Default/SmrPlanet.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -149,7 +149,7 @@
 block discarded – undo
149 149
 
150 150
 	public function getInterestRate(): float {
151 151
 		$level = $this->getLevel();
152
-		return match (true) {
152
+		return match(true) {
153 153
 			$level < 9 => .0404,
154 154
 			$level < 19 => .0609,
155 155
 			$level < 29 => .1236,
Please login to merge, or discard this patch.
src/lib/Default/AbstractSmrPort.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -278,7 +278,7 @@  discard block
 block discarded – undo
278 278
 		if (!isset($this->goodDistances[$goodID])) {
279 279
 			$x = Globals::getGood($goodID);
280 280
 			// Calculate distance to the opposite of the offered transaction
281
-			$x['TransactionType'] = match ($this->getGoodTransaction($goodID)) {
281
+			$x['TransactionType'] = match($this->getGoodTransaction($goodID)) {
282 282
 				TRADER_BUYS => TRADER_SELLS,
283 283
 				TRADER_SELLS => TRADER_BUYS,
284 284
 			};
@@ -426,7 +426,7 @@  discard block
 block discarded – undo
426 426
 		if ($level === null) {
427 427
 			$level = $this->getLevel();
428 428
 		}
429
-		return match (true) {
429
+		return match(true) {
430 430
 			$level <= 2 => 1,
431 431
 			$level <= 6 => 2,
432 432
 			$level >= 7 => 3,
Please login to merge, or discard this patch.
src/lib/Default/SmrAlliance.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -339,7 +339,7 @@
 block discarded – undo
339 339
 	}
340 340
 
341 341
 	public function getRecruitType(): string {
342
-		return match (true) {
342
+		return match(true) {
343 343
 			!$this->isRecruiting() => self::RECRUIT_CLOSED,
344 344
 			empty($this->getPassword()) => self::RECRUIT_OPEN,
345 345
 			default => self::RECRUIT_PASSWORD,
Please login to merge, or discard this patch.
src/templates/Default/engine/Default/includes/SectorPlayers.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,7 +1,7 @@
 block discarded – undo
1 1
 <?php
2 2
 function getPlayerOptionClass($player, $other) {
3 3
 	// Returns the CSS relational class of player "other" relative to "player".
4
-	return match (true) {
4
+	return match(true) {
5 5
 		$player->traderNAPAlliance($other) => 'friendly',
6 6
 		$other->canFight() => 'enemy',
7 7
 		default => 'neutral',
Please login to merge, or discard this patch.
src/lib/Default/AbstractSmrPlayer.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -609,7 +609,7 @@  discard block
 block discarded – undo
609 609
 	}
610 610
 
611 611
 	public function getScoutMessageGroupLimit(): int {
612
-		return match ($this->groupScoutMessages) {
612
+		return match($this->groupScoutMessages) {
613 613
 			'ALWAYS' => 0,
614 614
 			'AUTO' => MESSAGES_PER_PAGE,
615 615
 			'NEVER' => PHP_INT_MAX,
@@ -726,7 +726,7 @@  discard block
 block discarded – undo
726 726
 
727 727
 		// If expires not specified, use default based on message type
728 728
 		if ($expires === null) {
729
-			$expires = match ($messageTypeID) {
729
+			$expires = match($messageTypeID) {
730 730
 				MSG_GLOBAL => 3600, // 1h
731 731
 				MSG_PLAYER => 86400 * 31, // 1 month
732 732
 				MSG_PLANET => 86400 * 7, // 1 week
@@ -1838,7 +1838,7 @@  discard block
 block discarded – undo
1838 1838
 	public function getClaimableBounties(string $type = null): array {
1839 1839
 		$bounties = [];
1840 1840
 		$query = 'SELECT * FROM bounty WHERE claimer_id=' . $this->db->escapeNumber($this->getAccountID()) . ' AND game_id=' . $this->db->escapeNumber($this->getGameID());
1841
-		$query .= match ($type) {
1841
+		$query .= match($type) {
1842 1842
 			'HQ', 'UG' => ' AND type=' . $this->db->escapeString($type),
1843 1843
 			null => '',
1844 1844
 		};
@@ -2003,13 +2003,13 @@  discard block
 block discarded – undo
2003 2003
 			$dbResult = $this->db->read('SELECT type,amount FROM player_hof WHERE ' . $this->SQL);
2004 2004
 			$this->HOF = [];
2005 2005
 			foreach ($dbResult->records() as $dbRecord) {
2006
-				$hof =& $this->HOF;
2006
+				$hof = & $this->HOF;
2007 2007
 				$typeList = explode(':', $dbRecord->getString('type'));
2008 2008
 				foreach ($typeList as $type) {
2009 2009
 					if (!isset($hof[$type])) {
2010 2010
 						$hof[$type] = [];
2011 2011
 					}
2012
-					$hof =& $hof[$type];
2012
+					$hof = & $hof[$type];
2013 2013
 				}
2014 2014
 				$hof = $dbRecord->getFloat('amount');
2015 2015
 			}
@@ -2088,8 +2088,8 @@  discard block
 block discarded – undo
2088 2088
 		}
2089 2089
 		self::$HOFVis[$hofType] = $visibility;
2090 2090
 
2091
-		$hof =& $this->HOF;
2092
-		$hofChanged =& $this->hasHOFChanged;
2091
+		$hof = & $this->HOF;
2092
+		$hofChanged = & $this->hasHOFChanged;
2093 2093
 		$new = false;
2094 2094
 		foreach ($typeList as $type) {
2095 2095
 			if (!isset($hofChanged[$type])) {
@@ -2099,8 +2099,8 @@  discard block
 block discarded – undo
2099 2099
 				$hof[$type] = [];
2100 2100
 				$new = true;
2101 2101
 			}
2102
-			$hof =& $hof[$type];
2103
-			$hofChanged =& $hofChanged[$type];
2102
+			$hof = & $hof[$type];
2103
+			$hofChanged = & $hofChanged[$type];
2104 2104
 		}
2105 2105
 		if ($hofChanged == null) {
2106 2106
 			$hofChanged = self::HOF_CHANGED;
@@ -2491,7 +2491,7 @@  discard block
 block discarded – undo
2491 2491
 	 * Returns the CSS class color to use when displaying the player's turns
2492 2492
 	 */
2493 2493
 	public function getTurnsColor(): string {
2494
-		return match ($this->getTurnsLevel()) {
2494
+		return match($this->getTurnsLevel()) {
2495 2495
 			'NONE', 'LOW' => 'red',
2496 2496
 			'MEDIUM' => 'yellow',
2497 2497
 			'HIGH' => 'green',
@@ -2766,7 +2766,7 @@  discard block
 block discarded – undo
2766 2766
 			'Starting Sector' => $this->getSectorID(),
2767 2767
 		];
2768 2768
 
2769
-		$this->missions[$missionID] =& $mission;
2769
+		$this->missions[$missionID] = & $mission;
2770 2770
 		$this->setupMissionStep($missionID);
2771 2771
 		$this->rebuildMission($missionID);
2772 2772
 
@@ -2815,7 +2815,7 @@  discard block
 block discarded – undo
2815 2815
 
2816 2816
 	public function claimMissionReward(int $missionID): string {
2817 2817
 		$this->getMissions();
2818
-		$mission =& $this->missions[$missionID];
2818
+		$mission = & $this->missions[$missionID];
2819 2819
 		if ($mission === false) {
2820 2820
 			throw new Exception('Unknown mission: ' . $missionID);
2821 2821
 		}
Please login to merge, or discard this patch.