Completed
Push — 3.0 ( c9909d...50b99c )
by Olivier
06:41
created
descriptor.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -27,9 +27,9 @@
 block discarded – undo
27 27
 			Model::EXTENDING => 'nodes',
28 28
 			Model::SCHEMA => [
29 29
 
30
-				'size' => [ 'integer', 'unsigned' => true ],
31
-				'mime' => [ 'varchar', 'charset' => 'ascii/general_ci' ],
32
-				'extension' => [ 'varchar', 16, 'charset' => 'ascii/general_ci' ],
30
+				'size' => ['integer', 'unsigned' => true],
31
+				'mime' => ['varchar', 'charset' => 'ascii/general_ci'],
32
+				'extension' => ['varchar', 16, 'charset' => 'ascii/general_ci'],
33 33
 				'description' => 'text'
34 34
 
35 35
 			]
Please login to merge, or discard this patch.
lib/Block/ManageBlock/DownloadColumn.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@
 block discarded – undo
11 11
  */
12 12
 class DownloadColumn extends ManageBlock\Column
13 13
 {
14
-	public function __construct(ManageBlock $manager, $id, array $options=[])
14
+	public function __construct(ManageBlock $manager, $id, array $options = [])
15 15
 	{
16 16
 		parent::__construct($manager, $id, [
17 17
 
Please login to merge, or discard this patch.
lib/Facets/SizeCriterion.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
 		{
30 30
 			$value = $modifiers['size'];
31 31
 
32
-			if (in_array($value, [ 'l', 'm', 's' ]))
32
+			if (in_array($value, ['l', 'm', 's']))
33 33
 			{
34 34
 				$filters['size'] = $value;
35 35
 			}
Please login to merge, or discard this patch.
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.
updates.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@  discard block
 block discarded – undo
62 62
 
63 63
 		foreach ($model->select("nid, path")->mode(\PDO::FETCH_NUM) as list($nid, $path))
64 64
 		{
65
-			$update('.' . pathinfo($path, PATHINFO_EXTENSION), $nid);
65
+			$update('.'.pathinfo($path, PATHINFO_EXTENSION), $nid);
66 66
 		}
67 67
 	}
68 68
 
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
 
85 85
 		foreach ($model->select("nid, uuid, path")->mode(\PDO::FETCH_NUM) as list($nid, $uuid, $path))
86 86
 		{
87
-			$path = $document_root . $path;
87
+			$path = $document_root.$path;
88 88
 
89 89
 			if (!file_exists($path))
90 90
 			{
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
 			}
95 95
 
96 96
 			$hash = $storage->add($path)->hash;
97
-			$index->add(IndexKey::from([ $nid, $uuid, $hash ]));
97
+			$index->add(IndexKey::from([$nid, $uuid, $hash]));
98 98
 		}
99 99
 
100 100
 		$model->remove_column('path');
Please login to merge, or discard this patch.
lib/Hooks.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@  discard block
 block discarded – undo
27 27
 	{
28 28
 		static $index;
29 29
 
30
-		return $index ?: $index = new FileStorageIndex(\ICanBoogie\REPOSITORY . 'files-index');
30
+		return $index ?: $index = new FileStorageIndex(\ICanBoogie\REPOSITORY.'files-index');
31 31
 	}
32 32
 
33 33
 	/**
@@ -39,6 +39,6 @@  discard block
 block discarded – undo
39 39
 	{
40 40
 		static $manager;
41 41
 
42
-		return $manager ?: $manager = new FileStorage(\ICanBoogie\REPOSITORY . 'files', $app->file_storage_index);
42
+		return $manager ?: $manager = new FileStorage(\ICanBoogie\REPOSITORY.'files', $app->file_storage_index);
43 43
 	}
44 44
 }
Please login to merge, or discard this patch.
lib/Routing/FilesController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
 		return new FileResponse($pathname, $this->request, [
81 81
 
82 82
 			FileResponse::OPTION_ETAG => $pathname->hash,
83
-			FileResponse::OPTION_FILENAME => $record->title . $record->extension,
83
+			FileResponse::OPTION_FILENAME => $record->title.$record->extension,
84 84
 			FileResponse::OPTION_MIME => $record->mime
85 85
 
86 86
 		]);
Please login to merge, or discard this patch.
lib/Routing/FilesAdminController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -79,7 +79,7 @@
 block discarded – undo
79 79
 		return new FileResponse($pathname, $this->request, [
80 80
 
81 81
 			FileResponse::OPTION_ETAG => $pathname->hash,
82
-			FileResponse::OPTION_FILENAME => $record->title . $record->extension,
82
+			FileResponse::OPTION_FILENAME => $record->title.$record->extension,
83 83
 			FileResponse::OPTION_MIME => $record->mime
84 84
 
85 85
 		]);
Please login to merge, or discard this patch.
lib/Operation/SaveOperation.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -111,17 +111,17 @@  discard block
 block discarded – undo
111 111
 		if ($file && $file->is_valid)
112 112
 		{
113 113
 			$filename = \ICanBoogie\generate_v4_uuid();
114
-			$pathname = \ICanBoogie\REPOSITORY . 'tmp' . DIRECTORY_SEPARATOR . $filename;
114
+			$pathname = \ICanBoogie\REPOSITORY.'tmp'.DIRECTORY_SEPARATOR.$filename;
115 115
 
116 116
 			$file->move($pathname);
117 117
 		}
118
-		else if ($path && strpos($path, \ICanBoogie\strip_root(\ICanBoogie\REPOSITORY . "files")) !== 0)
118
+		else if ($path && strpos($path, \ICanBoogie\strip_root(\ICanBoogie\REPOSITORY."files")) !== 0)
119 119
 		{
120 120
 			$file = $this->resolve_request_file_from_pathname($path);
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
 
@@ -161,7 +161,7 @@  discard block
 block discarded – undo
161 161
 				$error_message = $errors->add(
162 162
 					File::HTTP_FILE,
163 163
 					"Maximum file size is :size Mb",
164
-					[ ':size' => round($max_file_size / 1024) ]
164
+					[':size' => round($max_file_size / 1024)]
165 165
 				);
166 166
 			}
167 167
 
@@ -170,7 +170,7 @@  discard block
 block discarded – undo
170 170
 				$error_message = $errors->add(
171 171
 					File::HTTP_FILE,
172 172
 					"Only the following file types are accepted: %accepted.",
173
-					[ '%accepted' => implode(', ', $this->accept)
173
+					['%accepted' => implode(', ', $this->accept)
174 174
 				]);
175 175
 			}
176 176
 
@@ -220,7 +220,7 @@  discard block
 block discarded – undo
220 220
 	protected function resolve_request_file_from_pathname($pathname)
221 221
 	{
222 222
 		$filename = basename($pathname);
223
-		$info_pathname = \ICanBoogie\REPOSITORY . 'tmp' . DIRECTORY_SEPARATOR . $filename . '.info';
223
+		$info_pathname = \ICanBoogie\REPOSITORY.'tmp'.DIRECTORY_SEPARATOR.$filename.'.info';
224 224
 
225 225
 		if (!file_exists($info_pathname))
226 226
 		{
Please login to merge, or discard this patch.