Completed
Push — 3.0 ( bff830...62cd67 )
by Olivier
06:14
created
lib/Storage/Base64.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
 	 */
26 26
 	static public function encode($data)
27 27
 	{
28
-		return strtr(base64_encode($data), [ '+' => '-', '/' => '_' ]);
28
+		return strtr(base64_encode($data), ['+' => '-', '/' => '_']);
29 29
 	}
30 30
 
31 31
 	/**
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
 	 */
38 38
 	static public function decode($data)
39 39
 	{
40
-		return base64_decode(strtr($data, [ '-' => '+', '_' => '/' ]));
40
+		return base64_decode(strtr($data, ['-' => '+', '_' => '/']));
41 41
 	}
42 42
 
43 43
 	/**
Please login to merge, or discard this patch.
lib/Storage/FileStorage.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
 	{
70 70
 		$this->assert_hash_is_used($hash);
71 71
 
72
-		$key = IndexKey::from([ $nid, $uuid, $hash ]);
72
+		$key = IndexKey::from([$nid, $uuid, $hash]);
73 73
 
74 74
 		$this->index->add($key);
75 75
 
@@ -204,7 +204,7 @@  discard block
 block discarded – undo
204 204
 	{
205 205
 		$hash = $hash ?: $this->hash($pathname);
206 206
 
207
-		return Pathname::from([ $this->root, $hash ]);
207
+		return Pathname::from([$this->root, $hash]);
208 208
 	}
209 209
 
210 210
 	/**
Please login to merge, or discard this patch.
lib/Operation/UploadOperation.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -93,12 +93,12 @@
 block discarded – undo
93 93
 
94 94
 		if ($max_file_size && $max_file_size < $file->size)
95 95
 		{
96
-			$error_message = $errors->format("Maximum file size is :size Mb", [ ':size' => round($max_file_size / 1024) ]);
96
+			$error_message = $errors->format("Maximum file size is :size Mb", [':size' => round($max_file_size / 1024)]);
97 97
 		}
98 98
 
99 99
 		if (!$file->match($this->accept))
100 100
 		{
101
-			$error_message = $errors->format("Only the following file types are accepted: %accepted.", [ '%accepted' => implode(', ', $this->accept) ]);
101
+			$error_message = $errors->format("Only the following file types are accepted: %accepted.", ['%accepted' => implode(', ', $this->accept)]);
102 102
 		}
103 103
 
104 104
 		if ($error_message)
Please login to merge, or discard this patch.
lib/Operation/SaveOperation.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
 
122 122
 			if (!$file)
123 123
 			{
124
-				$this->response->errors->add(File::HTTP_FILE, "Invalid or deleted file: %pathname", [ 'pathname' => $path ]);
124
+				$this->response->errors->add(File::HTTP_FILE, "Invalid or deleted file: %pathname", ['pathname' => $path]);
125 125
 			}
126 126
 		}
127 127
 
@@ -158,12 +158,12 @@  discard block
 block discarded – undo
158 158
 
159 159
 			if ($max_file_size && $max_file_size < $file->size)
160 160
 			{
161
-				$error_message = $errors->format("Maximum file size is :size Mb", [ ':size' => round($max_file_size / 1024) ]);
161
+				$error_message = $errors->format("Maximum file size is :size Mb", [':size' => round($max_file_size / 1024)]);
162 162
 			}
163 163
 
164 164
 			if ($this->accept && !$file->match($this->accept))
165 165
 			{
166
-				$error_message = $errors->format("Only the following file types are accepted: %accepted.", [ '%accepted' => implode(', ', $this->accept) ]);
166
+				$error_message = $errors->format("Only the following file types are accepted: %accepted.", ['%accepted' => implode(', ', $this->accept)]);
167 167
 			}
168 168
 
169 169
 			if ($error_message)
Please login to merge, or discard this patch.
lib/Module.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
 			}
49 49
 			else
50 50
 			{
51
-				$errors->add($this->id, "Unable to create %directory directory, its parent is not writable.", [ '%directory' => $path ]);
51
+				$errors->add($this->id, "Unable to create %directory directory, its parent is not writable.", ['%directory' => $path]);
52 52
 			}
53 53
 		}
54 54
 
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 			}
71 71
 			else
72 72
 			{
73
-				$errors->add($this->id, "Unable to create %directory directory, its parent is not writable", [ '%directory' => $path ]);
73
+				$errors->add($this->id, "Unable to create %directory directory, its parent is not writable", ['%directory' => $path]);
74 74
 			}
75 75
 		}
76 76
 
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
 			}
93 93
 			else
94 94
 			{
95
-				$errors->add($this->id, 'Unable to create %directory directory, its parent is not writable', [ '%directory' => $path ]);
95
+				$errors->add($this->id, 'Unable to create %directory directory, its parent is not writable', ['%directory' => $path]);
96 96
 			}
97 97
 		}
98 98
 
@@ -122,7 +122,7 @@  discard block
 block discarded – undo
122 122
 
123 123
 		if (!is_dir($path))
124 124
 		{
125
-			$errors->add($this->id, "The %directory directory is missing.", [ '%directory' => $path ]);
125
+			$errors->add($this->id, "The %directory directory is missing.", ['%directory' => $path]);
126 126
 		}
127 127
 
128 128
 		#
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
 
134 134
 		if (!is_dir($path))
135 135
 		{
136
-			$errors->add($this->id, "The %directory directory is missing.", [ '%directory' => $path ]);
136
+			$errors->add($this->id, "The %directory directory is missing.", ['%directory' => $path]);
137 137
 		}
138 138
 
139 139
 		return parent::is_installed($errors);
@@ -145,14 +145,14 @@  discard block
 block discarded – undo
145 145
 
146 146
 		if (!is_dir($path))
147 147
 		{
148
-			\ICanBoogie\log_error('The directory %directory does not exists', [ '%directory' => $path ]);
148
+			\ICanBoogie\log_error('The directory %directory does not exists', ['%directory' => $path]);
149 149
 
150 150
 			return;
151 151
 		}
152 152
 
153 153
 		if (!is_writable($path))
154 154
 		{
155
-			\ICanBoogie\log_error('The directory %directory is not writable', [ '%directory' => $path ]);
155
+			\ICanBoogie\log_error('The directory %directory is not writable', ['%directory' => $path]);
156 156
 
157 157
 			return;
158 158
 		}
Please login to merge, or discard this patch.