GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Passed
Pull Request — dev (#2644)
by
unknown
13:38
created
nzedb/ReleaseExtra.php 1 patch
Braces   +7 added lines, -4 removed lines patch added patch discarded remove patch
@@ -167,15 +167,18 @@  discard block
 block discarded – undo
167 167
 
168 168
 				if ($audio->get('language') !== null) {
169 169
 					$audioLanguage = $audio->get('language');
170
-					if (\is_array($audioLanguage)) { // If we have an array
171
-						foreach ($audioLanguage as $language) { // search through the list
170
+					if (\is_array($audioLanguage)) {
171
+// If we have an array
172
+						foreach ($audioLanguage as $language) {
173
+// search through the list
172 174
 							if (\strlen($language) === 2) {
173 175
 								$audioLanguage = $language; // and use the first two letter code.
174 176
 								break;
175 177
 							}
176 178
 						}
177 179
 
178
-						if (\is_array($audioLanguage)) { // If it is still an array...
180
+						if (\is_array($audioLanguage)) {
181
+// If it is still an array...
179 182
 							$audioLanguage = \implode(', ', $audioLanguage); // collapse it.
180 183
 						}
181 184
 					}
@@ -304,7 +307,7 @@  discard block
 block discarded – undo
304 307
 							$overallbitrate = $track['Overall_bit_rate'];
305 308
 						}
306 309
 						if (isset($track['Unique_ID'])) {
307
-							if(preg_match('/\(0x(?P<hash>[0-9a-f]{32})\)/i', $track['Unique_ID'], $matches)){
310
+							if(preg_match('/\(0x(?P<hash>[0-9a-f]{32})\)/i', $track['Unique_ID'], $matches)) {
308 311
 								$uniqueid = $matches['hash'];
309 312
 								$this->addUID($releaseID, $uniqueid);
310 313
 							}
Please login to merge, or discard this patch.
app/tests/cases/models/CountriesTest.php 1 patch
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -6,9 +6,13 @@
 block discarded – undo
6 6
 
7 7
 class CountriesTest extends \lithium\test\Unit
8 8
 {
9
-	public function setUp() {}
9
+	public function setUp()
10
+	{
11
+}
10 12
 
11
-	public function tearDown() {}
13
+	public function tearDown()
14
+	{
15
+}
12 16
 
13 17
 
14 18
 }
Please login to merge, or discard this patch.
app/tests/cases/controllers/CountriesControllerTest.php 1 patch
Braces   +21 added lines, -7 removed lines patch added patch discarded remove patch
@@ -6,15 +6,29 @@
 block discarded – undo
6 6
 
7 7
 class CountriesControllerTest extends \lithium\test\Unit
8 8
 {
9
-	public function setUp() {}
9
+	public function setUp()
10
+	{
11
+}
10 12
 
11
-	public function tearDown() {}
13
+	public function tearDown()
14
+	{
15
+}
12 16
 
13
-	public function testIndex() {}
14
-	public function testView() {}
15
-	public function testAdd() {}
16
-	public function testEdit() {}
17
-	public function testDelete() {}
17
+	public function testIndex()
18
+	{
19
+}
20
+	public function testView()
21
+	{
22
+}
23
+	public function testAdd()
24
+	{
25
+}
26
+	public function testEdit()
27
+	{
28
+}
29
+	public function testDelete()
30
+	{
31
+}
18 32
 }
19 33
 
20 34
 ?>
Please login to merge, or discard this patch.
app/controllers/CountriesController.php 1 patch
Braces   +10 added lines, -5 removed lines patch added patch discarded remove patch
@@ -7,17 +7,20 @@  discard block
 block discarded – undo
7 7
 
8 8
 class CountriesController extends \lithium\action\Controller
9 9
 {
10
-	public function index() {
10
+	public function index()
11
+	{
11 12
 		$countries = Countries::all();
12 13
 		return compact('countries');
13 14
 	}
14 15
 
15
-	public function view() {
16
+	public function view()
17
+	{
16 18
 		$country = Countries::first($this->request->id);
17 19
 		return compact('country');
18 20
 	}
19 21
 
20
-	public function add() {
22
+	public function add()
23
+	{
21 24
 		$country = Countries::create();
22 25
 
23 26
 		if (($this->request->data) && $country->save($this->request->data)) {
@@ -26,7 +29,8 @@  discard block
 block discarded – undo
26 29
 		return compact('country');
27 30
 	}
28 31
 
29
-	public function edit() {
32
+	public function edit()
33
+	{
30 34
 		$country = Countries::find($this->request->id);
31 35
 
32 36
 		if (!$country) {
@@ -38,7 +42,8 @@  discard block
 block discarded – undo
38 42
 		return compact('country');
39 43
 	}
40 44
 
41
-	public function delete() {
45
+	public function delete()
46
+	{
42 47
 		if (!$this->request->is('post') && !$this->request->is('delete')) {
43 48
 			$msg = "Countries::delete can only be called with http:post or http:delete.";
44 49
 			throw new DispatchException($msg);
Please login to merge, or discard this patch.
app/controllers/VideosController.php 1 patch
Braces   +12 added lines, -6 removed lines patch added patch discarded remove patch
@@ -23,19 +23,23 @@  discard block
 block discarded – undo
23 23
 use lithium\action\DispatchException;
24 24
 
25 25
 
26
-class VideosController extends \lithium\action\Controller {
26
+class VideosController extends \lithium\action\Controller
27
+{
27 28
 
28
-	public function index() {
29
+	public function index()
30
+	{
29 31
 		$videos = Videos::all();
30 32
 		return compact('videos');
31 33
 	}
32 34
 
33
-	public function view() {
35
+	public function view()
36
+	{
34 37
 		$video = Videos::first($this->request->id);
35 38
 		return compact('video');
36 39
 	}
37 40
 
38
-	public function add() {
41
+	public function add()
42
+	{
39 43
 		$video = Videos::create();
40 44
 
41 45
 		if ($this->request->data && $video->save($this->request->data)) {
@@ -44,7 +48,8 @@  discard block
 block discarded – undo
44 48
 		return compact('video');
45 49
 	}
46 50
 
47
-	public function edit() {
51
+	public function edit()
52
+	{
48 53
 		$video = Videos::find($this->request->id);
49 54
 
50 55
 		if (!$video) {
@@ -56,7 +61,8 @@  discard block
 block discarded – undo
56 61
 		return compact('video');
57 62
 	}
58 63
 
59
-	public function delete() {
64
+	public function delete()
65
+	{
60 66
 		if (!$this->request->is('post') && !$this->request->is('delete')) {
61 67
 			$msg = 'Videos::delete can only be called with http:post or http:delete.';
62 68
 			throw new DispatchException($msg);
Please login to merge, or discard this patch.
nzedb/http/XML_Response.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -246,8 +246,7 @@  discard block
 block discarded – undo
246 246
 	{
247 247
 		$this->xml->startElement('categories');
248 248
 
249
-		foreach ($this->server['categories'] AS $p)
250
-		{
249
+		foreach ($this->server['categories'] AS $p) {
251 250
 			$this->xml->startElement('category');
252 251
 			$this->xml->writeAttribute('id', $p['id']);
253 252
 			$this->xml->writeAttribute('name', html_entity_decode($p['title']));
@@ -255,8 +254,7 @@  discard block
 block discarded – undo
255 254
 				$this->xml->writeAttribute('description', html_entity_decode($p['description']));
256 255
 			}
257 256
 
258
-			foreach($p['subcatlist'] AS $c)
259
-			{
257
+			foreach($p['subcatlist'] AS $c) {
260 258
 				$this->xml->startElement('subcat');
261 259
 				$this->xml->writeAttribute('id', $c['id']);
262 260
 				$this->xml->writeAttribute('name', html_entity_decode($c['title']));
Please login to merge, or discard this patch.
nzedb/NNTP.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -981,8 +981,7 @@
 block discarded – undo
981 981
 		$iterator = 0;
982 982
 
983 983
 		// Loop over strings of headers.
984
-		foreach ($data as $key => &$header)
985
-		{
984
+		foreach ($data as $key => &$header) {
986 985
 			// Split the individual headers by tab.
987 986
 			$header = explode("\t", $header);
988 987
 
Please login to merge, or discard this patch.
nzedb/db/DbUpdate.php 1 patch
Braces   +9 added lines, -13 removed lines patch added patch discarded remove patch
@@ -109,15 +109,16 @@  discard block
 block discarded – undo
109 109
 		$sql = 'LOAD DATA ' . $local . 'INFILE "%s" IGNORE INTO TABLE `%s` FIELDS TERMINATED BY "\t" ' .
110 110
 			$enclosedby . ' LINES TERMINATED BY "\r\n" IGNORE 1 LINES (%s)';
111 111
 		foreach ($files as $file) {
112
-			if ($show === true)
113
-			{
112
+			if ($show === true) {
114 113
 				echo "File: $file\n";
115 114
 			}
116 115
 
117 116
 			$fileTarget = '/tmp/' . pathinfo($file, PATHINFO_BASENAME);
118
-			if (\copy($file, $fileTarget)) // Copy to a directory accessible to all (for mysql user)
117
+			if (\copy($file, $fileTarget)) {
118
+				// Copy to a directory accessible to all (for mysql user)
119 119
 			{
120 120
 				$file = $fileTarget;
121
+			}
121 122
 				\chmod($file, 0775);
122 123
 			} else {
123 124
 				echo 'Failed to copy file: ' . $file . '</br>' . \PHP_EOL;
@@ -125,28 +126,23 @@  discard block
 block discarded – undo
125 126
 			}
126 127
 
127 128
 			if (is_readable($file)) {
128
-				if (preg_match($options['regex'], $file, $matches))
129
-				{
129
+				if (preg_match($options['regex'], $file, $matches)) {
130 130
 					$table = $matches['table'];
131 131
 					// Get the first line of the file which holds the columns used.
132 132
 					$handle = @fopen($file, 'r');
133
-					if (is_resource($handle))
134
-					{
133
+					if (is_resource($handle)) {
135 134
 						$line = fgets($handle);
136 135
 						fclose($handle);
137
-						if ($line === false)
138
-						{
136
+						if ($line === false) {
139 137
 							echo "FAILED reading first line of '$file'\n";
140 138
 							continue;
141 139
 						}
142 140
 						$fields = trim($line);
143 141
 
144
-						if ($show === true)
145
-						{
142
+						if ($show === true) {
146 143
 							echo "Inserting data into table: '$table'\n";
147 144
 						}
148
-						if (Misc::isWin())
149
-						{
145
+						if (Misc::isWin()) {
150 146
 							$file = str_replace("\\", '\/', $file);
151 147
 						}
152 148
 						$this->pdo->exec(sprintf($sql, $file, $table, $fields));
Please login to merge, or discard this patch.
nzedb/utility/Misc.php 1 patch
Braces   +12 added lines, -4 removed lines patch added patch discarded remove patch
@@ -775,8 +775,10 @@  discard block
 block discarded – undo
775 775
 			//get attributes from all namespaces
776 776
 			foreach ($xml->attributes($namespace) as $attributeName => $attribute) {
777 777
 				//replace characters in attribute name
778
-				if ($options['keySearch']) $attributeName =
778
+				if ($options['keySearch']) {
779
+					$attributeName =
779 780
 					str_replace($options['keySearch'], $options['keyReplace'], $attributeName);
781
+				}
780 782
 				$attributeKey = $options['attributePrefix']
781 783
 					. ($prefix ? $prefix . $options['namespaceSeparator'] : '')
782 784
 					. $attributeName;
@@ -790,10 +792,14 @@  discard block
 block discarded – undo
790 792
 				$childProperties = current($childArray);
791 793
 
792 794
 				//replace characters in tag name
793
-				if ($options['keySearch']) $childTagName =
795
+				if ($options['keySearch']) {
796
+					$childTagName =
794 797
 					str_replace($options['keySearch'], $options['keyReplace'], $childTagName);
798
+				}
795 799
 				//add namespace prefix, if any
796
-				if ($prefix) $childTagName = $prefix . $options['namespaceSeparator'] . $childTagName;
800
+				if ($prefix) {
801
+					$childTagName = $prefix . $options['namespaceSeparator'] . $childTagName;
802
+				}
797 803
 
798 804
 				if (!isset($tagsArray[$childTagName])) {
799 805
 					//only entry with this key
@@ -817,7 +823,9 @@  discard block
 block discarded – undo
817 823
 		//get text content of node
818 824
 		$textContentArray = array();
819 825
 		$plainText = trim((string)$xml);
820
-		if ($plainText !== '') $textContentArray[$options['textContent']] = $plainText;
826
+		if ($plainText !== '') {
827
+			$textContentArray[$options['textContent']] = $plainText;
828
+		}
821 829
 
822 830
 		//stick it all together
823 831
 		$propertiesArray = !$options['autoText'] || $attributesArray || $tagsArray || ($plainText === '')
Please login to merge, or discard this patch.