Skip to content

Commit

Permalink
Merge pull request #625 from The-MEO/fix/ArgumentCountError
Browse files Browse the repository at this point in the history
FIX ArgumentCountError in UploadController::saveMedia
  • Loading branch information
sergix44 authored Jan 23, 2025
2 parents 5fed0e7 + 2eb0375 commit e910f7e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Controllers/UploadController.php
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,6 @@ public function uploadEndpoint(Request $request, Response $response): Response
/**
* @param Request $request
* @param Response $response
* @param $code
* @return UploadedFileInterface
* @throws ValidationException
*/
Expand Down Expand Up @@ -179,11 +178,12 @@ protected function validateUser(Request $request, Response $response, UploadedFi
* @param Response $response
* @param UploadedFileInterface $file
* @param $user
* @param $code
* @return Response
* @throws \League\Flysystem\FileExistsException
* @throws \League\Flysystem\FileNotFoundException
*/
protected function saveMedia(Response $response, UploadedFileInterface $file, $user, $code)
protected function saveMedia(Response $response, UploadedFileInterface $file, $user, $code = null)
{
if ($code === null) {
do {
Expand Down

0 comments on commit e910f7e

Please sign in to comment.