diff --git a/app/Http/Controllers/UserController.php b/app/Http/Controllers/UserController.php index 3885ab4..1ff621f 100755 --- a/app/Http/Controllers/UserController.php +++ b/app/Http/Controllers/UserController.php @@ -60,11 +60,14 @@ class UserController extends Controller { $request->validate([ 'link' => 'required', - 'title' => 'required', + 'title' => '', 'button' => 'required' ]); $link = $request->link; + if ($request->title == '') + $title = $request->button; + else $title = $request->title; $button = $request->button; diff --git a/resources/views/studio/add-link.blade.php b/resources/views/studio/add-link.blade.php index 0305ac0..bfe608e 100755 --- a/resources/views/studio/add-link.blade.php +++ b/resources/views/studio/add-link.blade.php @@ -7,20 +7,26 @@
@csrf
- +
- +
- + +
+