Test Failed
Branch php82 (70c00d)
by Andreas
15:04
created
plugins/files/php/plugin.files.php 1 patch
Switch Indentation   +24 added lines, -24 removed lines patch added patch discarded remove patch
@@ -45,37 +45,37 @@
 block discarded – undo
45 45
 
46 46
 			case 'server.index.load.custom':
47 47
 				switch ($data['name']) {
48
-				case 'files_get_recipients':
49
-					RecipientHandler::doGetRecipients();
50
-					break;
48
+					case 'files_get_recipients':
49
+						RecipientHandler::doGetRecipients();
50
+						break;
51 51
 
52
-				case 'download_file':
53
-					DownloadHandler::doDownload();
54
-					break;
52
+					case 'download_file':
53
+						DownloadHandler::doDownload();
54
+						break;
55 55
 
56
-				case 'upload_file':
57
-					UploadHandler::doUpload();
58
-					break;
56
+					case 'upload_file':
57
+						UploadHandler::doUpload();
58
+						break;
59 59
 
60
-				case 'form':
61
-					if (isset($_GET['backend'])) {
62
-						$backend = urldecode($_GET["backend"]);
63
-					}
64
-					else {
65
-						$backend = '';
66
-					}
67
-					$backendstore = Files\Backend\BackendStore::getInstance();
60
+					case 'form':
61
+						if (isset($_GET['backend'])) {
62
+							$backend = urldecode($_GET["backend"]);
63
+						}
64
+						else {
65
+							$backend = '';
66
+						}
67
+						$backendstore = Files\Backend\BackendStore::getInstance();
68 68
 
69
-					if ($backendstore->backendExists($backend)) {
70
-						$backendInstance = $backendstore->getInstanceOfBackend($backend);
71
-						$formdata = $backendInstance->getFormConfig();
69
+						if ($backendstore->backendExists($backend)) {
70
+							$backendInstance = $backendstore->getInstanceOfBackend($backend);
71
+							$formdata = $backendInstance->getFormConfig();
72 72
 
73
-						exit($formdata);
74
-					}
73
+							exit($formdata);
74
+						}
75 75
 
76
-						exit("Specified backend does not exist!");
76
+							exit("Specified backend does not exist!");
77 77
 
78
-					break;
78
+						break;
79 79
 			}
80 80
 			break;
81 81
 		}
Please login to merge, or discard this patch.
plugins/smime/php/lib/X509.php 1 patch
Switch Indentation   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -15,31 +15,31 @@
 block discarded – undo
15 15
 		$tag = $this->peek();
16 16
 
17 17
 		switch ($tag) {
18
-		case 0:
19
-			$res['otherName'] = $this->oid(-6);
20
-			break;
21
-
22
-		case 1:
23
-			$res['rfc822Name'] = $this->next(-22);
24
-			break;
25
-
26
-		case 2:
27
-			$res['dNSName'] = $this->next(-22);
28
-			break;
29
-
30
-		case 4:
31
-			$this->next(4);
32
-			$res['directoryName'] = $this->name();
33
-			$res['directoryName_'] = $this->nameasstring($res['directoryName']);
34
-			break;
35
-
36
-		case 6:
37
-			$res['uniformResourceIdentifier'] = $this->next(-22);
38
-			break;
39
-
40
-		default:
41
-			throw new \Exception("Unsupported GeneralName: {$tag}");
42
-#                trigger_error("Unsupported GeneralName: $tag", E_USER_ERROR);
18
+			case 0:
19
+				$res['otherName'] = $this->oid(-6);
20
+				break;
21
+
22
+			case 1:
23
+				$res['rfc822Name'] = $this->next(-22);
24
+				break;
25
+
26
+			case 2:
27
+				$res['dNSName'] = $this->next(-22);
28
+				break;
29
+
30
+			case 4:
31
+				$this->next(4);
32
+				$res['directoryName'] = $this->name();
33
+				$res['directoryName_'] = $this->nameasstring($res['directoryName']);
34
+				break;
35
+
36
+			case 6:
37
+				$res['uniformResourceIdentifier'] = $this->next(-22);
38
+				break;
39
+
40
+			default:
41
+				throw new \Exception("Unsupported GeneralName: {$tag}");
42
+	#                trigger_error("Unsupported GeneralName: $tag", E_USER_ERROR);
43 43
 		}
44 44
 
45 45
 		return $res;
Please login to merge, or discard this patch.
plugins/smime/php/class.pluginsmimemodule.php 2 patches
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,9 +25,11 @@
 block discarded – undo
25 25
 	 * @return bool true on success or false on failure
26 26
 	 */
27 27
 	public function execute() {
28
-		foreach ($this->data as $actionType => $actionData) try {
28
+		foreach ($this->data as $actionType => $actionData) {
29
+			try {
29 30
 			if (!isset($actionType))
30 31
 				continue;
32
+		}
31 33
 			switch ($actionType) {
32 34
 			case 'certificate':
33 35
 				$data = $this->verifyCertificate($actionData);
Please login to merge, or discard this patch.
Switch Indentation   +50 added lines, -50 removed lines patch added patch discarded remove patch
@@ -29,62 +29,62 @@
 block discarded – undo
29 29
 			if (!isset($actionType))
30 30
 				continue;
31 31
 			switch ($actionType) {
32
-			case 'certificate':
33
-				$data = $this->verifyCertificate($actionData);
34
-				$response = [
35
-					'type' => 3,
36
-					'status' => $data['status'],
37
-					'message' => $data['message'],
38
-					'data' => $data['data'],
39
-				];
40
-				$this->addActionData('certificate', $response);
41
-				$GLOBALS['bus']->addData($this->getResponseData());
42
-				break;
32
+				case 'certificate':
33
+					$data = $this->verifyCertificate($actionData);
34
+					$response = [
35
+						'type' => 3,
36
+						'status' => $data['status'],
37
+						'message' => $data['message'],
38
+						'data' => $data['data'],
39
+					];
40
+					$this->addActionData('certificate', $response);
41
+					$GLOBALS['bus']->addData($this->getResponseData());
42
+					break;
43 43
 
44
-			case 'passphrase':
45
-				$data = $this->verifyPassphrase($actionData);
46
-				$response = [
47
-					'type' => 3,
48
-					'status' => $data['status'],
49
-				];
50
-				$this->addActionData('passphrase', $response);
51
-				$GLOBALS['bus']->addData($this->getResponseData());
52
-				break;
44
+				case 'passphrase':
45
+					$data = $this->verifyPassphrase($actionData);
46
+					$response = [
47
+						'type' => 3,
48
+						'status' => $data['status'],
49
+					];
50
+					$this->addActionData('passphrase', $response);
51
+					$GLOBALS['bus']->addData($this->getResponseData());
52
+					break;
53 53
 
54
-			case 'changepassphrase':
55
-				$data = $this->changePassphrase($actionData);
56
-				if ($data === CHANGE_PASSPHRASE_SUCCESS) {
57
-					// Reset cached passphrase.
58
-					$encryptionStore = EncryptionStore::getInstance();
59
-					withPHPSession(function () use ($encryptionStore) {
60
-						$encryptionStore->add('smime', '');
61
-					});
62
-				}
63
-				$response = [
64
-					'type' => 3,
65
-					'code' => $data,
66
-				];
67
-				$this->addActionData('changepassphrase', $response);
68
-				$GLOBALS['bus']->addData($this->getResponseData());
69
-				break;
54
+				case 'changepassphrase':
55
+					$data = $this->changePassphrase($actionData);
56
+					if ($data === CHANGE_PASSPHRASE_SUCCESS) {
57
+						// Reset cached passphrase.
58
+						$encryptionStore = EncryptionStore::getInstance();
59
+						withPHPSession(function () use ($encryptionStore) {
60
+							$encryptionStore->add('smime', '');
61
+						});
62
+					}
63
+					$response = [
64
+						'type' => 3,
65
+						'code' => $data,
66
+					];
67
+					$this->addActionData('changepassphrase', $response);
68
+					$GLOBALS['bus']->addData($this->getResponseData());
69
+					break;
70 70
 
71
-			case 'list':
72
-				$data = $this->getPublicCertificates();
73
-				$this->addActionData('list', $data);
74
-				$GLOBALS['bus']->addData($this->getResponseData());
75
-				break;
71
+				case 'list':
72
+					$data = $this->getPublicCertificates();
73
+					$this->addActionData('list', $data);
74
+					$GLOBALS['bus']->addData($this->getResponseData());
75
+					break;
76 76
 
77
-			case 'delete':
78
-				// FIXME: handle multiple deletes? Separate function?
79
-				$entryid = $actionData['entryid'];
80
-				$root = mapi_msgstore_openentry($this->store);
81
-				mapi_folder_deletemessages($root, [hex2bin($entryid)]);
77
+				case 'delete':
78
+					// FIXME: handle multiple deletes? Separate function?
79
+					$entryid = $actionData['entryid'];
80
+					$root = mapi_msgstore_openentry($this->store);
81
+					mapi_folder_deletemessages($root, [hex2bin($entryid)]);
82 82
 
83
-				$this->sendFeedback(true);
84
-				break;
83
+					$this->sendFeedback(true);
84
+					break;
85 85
 
86
-			default:
87
-				$this->handleUnknownActionType($actionType);
86
+				default:
87
+					$this->handleUnknownActionType($actionType);
88 88
 			}
89 89
 		}
90 90
 		catch (Exception $e) {
Please login to merge, or discard this patch.
plugins/smime/php/class.certificate.php 1 patch
Switch Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -33,14 +33,14 @@
 block discarded – undo
33 33
 		}
34 34
 
35 35
 		switch ($this->status) {
36
-		case 'good':
37
-			return OCSP_CERT_STATUS_GOOD;
36
+			case 'good':
37
+				return OCSP_CERT_STATUS_GOOD;
38 38
 
39
-		case 'revoked':
40
-			return OCSP_CERT_STATUS_REVOKED;
39
+			case 'revoked':
40
+				return OCSP_CERT_STATUS_REVOKED;
41 41
 
42
-		default:
43
-			return OCSP_CERT_STATUS_UNKOWN;
42
+			default:
43
+				return OCSP_CERT_STATUS_UNKOWN;
44 44
 		}
45 45
 	}
46 46
 }
Please login to merge, or discard this patch.
plugins/smime/php/util.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -98,8 +98,9 @@
 block discarded – undo
98 98
 	// Get messages from certificates
99 99
 	foreach ($privateCerts as $privateCert) {
100 100
 		$privateCertMessage = mapi_msgstore_openentry($store, $privateCert[PR_ENTRYID]);
101
-		if ($privateCertMessage === false)
102
-			continue;
101
+		if ($privateCertMessage === false) {
102
+					continue;
103
+		}
103 104
 		$pkcs12 = "";
104 105
 		$certs = [];
105 106
 		// Read pkcs12 cert from message
Please login to merge, or discard this patch.
phpfastcache/lib/Phpfastcache/Exceptions/PhpfastcacheIOException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -24,8 +24,7 @@
 block discarded – undo
24 24
     /**
25 25
      * @inheritdoc
26 26
      */
27
-    public function __construct(string $message = "", int $code = 0, \Throwable $previous = null)
28
-    {
27
+    public function __construct(string $message = "", int $code = 0, \Throwable $previous = null) {
29 28
         $lastError = error_get_last();
30 29
         if ($lastError) {
31 30
             $message .= "\n";
Please login to merge, or discard this patch.
lib/Phpfastcache/Exceptions/PhpfastcacheCorruptedDataException.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,8 +22,7 @@
 block discarded – undo
22 22
      * @param string $message
23 23
      * @param mixed|null $corruptedData
24 24
      */
25
-    public function __construct(protected $message = '', protected mixed $corruptedData = null)
26
-    {
25
+    public function __construct(protected $message = '', protected mixed $corruptedData = null) {
27 26
         parent::__construct($message);
28 27
     }
29 28
 }
Please login to merge, or discard this patch.
vendor/phpfastcache/phpfastcache/lib/Phpfastcache/Drivers/Sqlite/Driver.php 1 patch
Braces   +15 added lines, -9 removed lines patch added patch discarded remove patch
@@ -106,7 +106,8 @@  discard block
 block discarded – undo
106 106
                 ]
107 107
             );
108 108
             $row = $stm->fetch(PDO::FETCH_ASSOC);
109
-        } catch (PDOException $e) {
109
+        }
110
+        catch (PDOException $e) {
110 111
             try {
111 112
                 $stm = $this->getDb($item->getEncodedKey(), true)
112 113
                     ->prepare("SELECT * FROM `caching` WHERE `keyword`=:keyword LIMIT 1");
@@ -116,7 +117,8 @@  discard block
 block discarded – undo
116 117
                     ]
117 118
                 );
118 119
                 $row = $stm->fetch(PDO::FETCH_ASSOC);
119
-            } catch (PDOException $e) {
120
+            }
121
+            catch (PDOException $e) {
120 122
                 return null;
121 123
             }
122 124
         }
@@ -168,8 +170,7 @@  discard block
 block discarded – undo
168 170
      * @param string $keyword
169 171
      * @return int
170 172
      */
171
-    public function getDbIndex(string $keyword)
172
-    {
173
+    public function getDbIndex(string $keyword) {
173 174
         if (!isset($this->indexing)) {
174 175
             $tableCreated = false;
175 176
             if (!file_exists($this->sqliteDir . '/indexing')) {
@@ -193,9 +194,11 @@  discard block
 block discarded – undo
193 194
             $row = $stm->fetch(PDO::FETCH_ASSOC);
194 195
             if (!isset($row['db'])) {
195 196
                 $db = 1;
196
-            } elseif ($row['db'] <= 1) {
197
+            }
198
+            elseif ($row['db'] <= 1) {
197 199
                 $db = 1;
198
-            } else {
200
+            }
201
+            else {
199 202
                 $db = $row['db'];
200 203
             }
201 204
 
@@ -221,7 +224,8 @@  discard block
 block discarded – undo
221 224
         $row = $stm->fetch(PDO::FETCH_ASSOC);
222 225
         if (isset($row['db']) && $row['db'] != '') {
223 226
             $db = $row['db'];
224
-        } else {
227
+        }
228
+        else {
225 229
             /*
226 230
              * Insert new to Indexing
227 231
              */
@@ -292,7 +296,8 @@  discard block
 block discarded – undo
292 296
             );
293 297
 
294 298
             return true;
295
-        } catch (PDOException $e) {
299
+        }
300
+        catch (PDOException $e) {
296 301
             return false;
297 302
         }
298 303
     }
@@ -314,7 +319,8 @@  discard block
 block discarded – undo
314 319
                     ':exp' => time(),
315 320
                 ]
316 321
             );
317
-        } catch (PDOException $e) {
322
+        }
323
+        catch (PDOException $e) {
318 324
             return false;
319 325
         }
320 326
     }
Please login to merge, or discard this patch.
phpfastcache/phpfastcache/lib/Phpfastcache/Drivers/Memcache/Driver.php 1 patch
Braces   +5 added lines, -4 removed lines patch added patch discarded remove patch
@@ -59,8 +59,7 @@  discard block
 block discarded – undo
59 59
      * @throws PhpfastcacheDriverCheckException
60 60
      * @throws PhpfastcacheIOException
61 61
      */
62
-    public function __construct(ConfigurationOption $config, string $instanceId, EventManagerInterface $em)
63
-    {
62
+    public function __construct(ConfigurationOption $config, string $instanceId, EventManagerInterface $em) {
64 63
         self::checkCollision('Memcache');
65 64
         $this->__parentConstruct($config, $instanceId, $em);
66 65
     }
@@ -107,14 +106,16 @@  discard block
 block discarded – undo
107 106
                  */
108 107
                 if (!empty($server['path'])) {
109 108
                     $this->instance->addServer($server['path'], 0);
110
-                } elseif (!empty($server['host'])) {
109
+                }
110
+                elseif (!empty($server['host'])) {
111 111
                     $this->instance->addServer($server['host'], $server['port']);
112 112
                 }
113 113
 
114 114
                 if (!empty($server['saslUser']) && !empty($server['saslPassword'])) {
115 115
                     throw new PhpfastcacheDriverException('Unlike Memcached, Memcache does not support SASL authentication');
116 116
                 }
117
-            } catch (Exception $e) {
117
+            }
118
+            catch (Exception $e) {
118 119
                 throw new PhpfastcacheDriverConnectException(
119 120
                     sprintf(
120 121
                         'Failed to connect to memcache host/path "%s" with the following error: %s',
Please login to merge, or discard this patch.