Refactor code with Pint

This commit is contained in:
brufdev
2025-01-26 19:54:29 +00:00
parent c1a4cee8fc
commit dd82dddf94
23 changed files with 61 additions and 61 deletions

View File

@@ -19,7 +19,7 @@ final class ProcessImportedFile
$name = $pathInfo['filename'];
$extension = $pathInfo['extension'] ?? '';
if (! in_array($extension, VaultFile::extensions())) {
if (!in_array($extension, VaultFile::extensions())) {
abort(400);
}
@@ -51,7 +51,7 @@ final class ProcessImportedFile
);
natcasesort($nodes);
$name .= count($nodes) && preg_match('/-(\d+)$/', end($nodes), $matches) === 1 ?
'-'.((int) $matches[1] + 1) :
'-' . ((int) $matches[1] + 1) :
'-1';
}