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
Pull Request — master (#869)
by Dan
04:03
created

SmrPlayer::getHome()   A

Complexity

Conditions 3
Paths 3

Size

Total Lines 10
Code Lines 6

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 3
eloc 6
c 1
b 0
f 0
nc 3
nop 0
dl 0
loc 10
rs 10
1
<?php declare(strict_types=1);
2
3
class SmrPlayer extends AbstractSmrPlayer {
4
5
	public function getHome() {
6
		if ($this->hasAlliance()) {
7
			$leaderID = $this->getAlliance()->getLeaderID();
8
			$this->db->query('SELECT home_sector_id FROM draft_leaders WHERE account_id = ' . $this->db->escapeNumber($leaderID) . ' AND game_id = ' . $this->db->escapeNumber($this->getGameID()));
9
			if ($this->db->nextRecord()) {
10
				return $this->db->getInt('home_sector_id');
11
			}
12
		}
13
		// Fallback to the standard home sector
14
		return parent::getHome();
15
	}
16
17
}
18