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 — master ( 2799eb...63eb51 )
by Dan
04:22
created

Menu::headquarters()   A

Complexity

Conditions 3
Paths 3

Size

Total Lines 19
Code Lines 16

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 3
eloc 16
nc 3
nop 0
dl 0
loc 19
rs 9.7333
c 0
b 0
f 0
1
<?php declare(strict_types=1);
2
3
class Menu extends AbstractMenu {
4
5
	// No bounties in Semi Wars games
6
	public static function headquarters() {
7
		global $var;
8
		$menu_items = [];
9
		$container = create_container('skeleton.php');
10
		$container['LocationID'] = $var['LocationID'];
11
12
		$location = SmrLocation::getLocation($var['LocationID']);
13
		if ($location->isHQ()) {
14
			$container['body'] = 'government.php';
15
			$menu_items[] = create_link($container, 'Government', 'nav');
16
			$container['body'] = 'military_payment_claim.php';
17
			$menu_items[] = create_link($container, 'Claim Military Payment', 'nav');
18
		} elseif ($location->isUG()) {
19
			$container['body'] = 'underground.php';
20
			$menu_items[] = create_link($container, 'Underground', 'nav');
21
		} else {
22
			throw new Exception("Location is not HQ or UG: " . $location->getName());
23
		}
24
		create_menu($menu_items);
25
	}
26
27
}
28