]> git.localhorst.tv Git - alttp.git/blobdiff - app/Http/Controllers/RoundController.php
chat bot protocol ui
[alttp.git] / app / Http / Controllers / RoundController.php
index 2b6c617acfbaa03d93df72544f4881d2036eb812..8ec2b84d010eb7519f4e1da796b2e7717e8d1e01 100644 (file)
@@ -43,11 +43,18 @@ class RoundController extends Controller
                $this->authorize('update', $round);
 
                $validatedData = $request->validate([
+                       'code' => 'array',
+                       'code.*' => 'string',
+                       'rolled_by' => 'nullable|exists:App\\Models\\User,id',
                        'seed' => 'url',
+                       'spoiler' => 'url',
                        'title' => 'string',
                ]);
 
+               $round->code = array_filter($validatedData['code']);
+               $round->rolled_by = $validatedData['rolled_by'];
                $round->seed = $validatedData['seed'];
+               $round->spoiler = $validatedData['spoiler'];
                $round->title = $validatedData['title'];
                $round->update();