From c8197254ce67b73520b19992b1518b9a75b6b1ed Mon Sep 17 00:00:00 2001 From: Rudiansyah Date: Sat, 16 Dec 2023 22:13:32 +0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=80=20chore(laravel.md):=20Add=20check?= =?UTF-8?q?er=20hasFile?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/_posts/laravel.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/source/_posts/laravel.md b/source/_posts/laravel.md index cedbbfb..fdd365c 100644 --- a/source/_posts/laravel.md +++ b/source/_posts/laravel.md @@ -734,6 +734,11 @@ if ($request->has(['name', 'email'])) { if ($request->hasAny(['name', 'email'])) { // } + +// if a file is present on request +if ($request->hasFile('image')) { + // +} ``` ### Old Input