cloudinary-laravel icon indicating copy to clipboard operation
cloudinary-laravel copied to clipboard

Update Validation of MediaAlly.php Trait

Open cw-alihyder opened this issue 3 years ago • 4 comments

It was giving an error on $request->file I just make it to validate whether the given parameter is actually an instance of the upload file or not.

cw-alihyder avatar Jul 31 '22 12:07 cw-alihyder

@cw-alihyder What error was it giving?

unicodeveloper avatar Aug 03 '22 08:08 unicodeveloper

it's not letting the user go to next keep throwing the Exception even if it's a file Instance.

cw-alihyder avatar Aug 03 '22 09:08 cw-alihyder

So how does your PR fix it? @cw-alihyder

unicodeveloper avatar Aug 04 '22 03:08 unicodeveloper

now my PR fixes this by validating whether the param is actually an instance of UploadedFile or not. If it will not instance of UploadedFile it will throw an exception. On the other hand, file_exist doesn't work with the UploadFile instance.

cw-alihyder avatar Aug 05 '22 13:08 cw-alihyder