Fix backend code styling

This commit is contained in:
MakingCG
2021-07-22 15:28:36 +00:00
committed by GitHub Actions
parent fffede1c10
commit 7cb485fb43
50 changed files with 80 additions and 97 deletions

View File

@@ -11,7 +11,7 @@ class CreateImageThumbnailAction
'image/jpeg',
'image/jpg',
'image/png',
'image/webp'
'image/webp',
];
/**
@@ -22,12 +22,10 @@ class CreateImageThumbnailAction
string $filename,
string $user_id
): string | null {
$mimeType = Storage::disk('local')->mimeType($file_path);
// Create thumbnail from image
if (in_array($mimeType, $this->availableFormats)) {
// Get thumbnail name
$thumbnail = "thumbnail-$filename";

View File

@@ -12,7 +12,8 @@ class UploadFileController extends Controller
public function __construct(
public UploadFileAction $uploadFiles,
public FakeUploadFileAction $fakeUploadFile,
) {}
) {
}
/**
* Upload file for authenticated master|editor user
@@ -20,7 +21,6 @@ class UploadFileController extends Controller
public function __invoke(
UploadRequest $request,
): File | array {
if (is_demo_account('howdy@hi5ve.digital')) {
return ($this->fakeUploadFile)($request);
}