]> git.localhorst.tv Git - alttp.git/blobdiff - app/Http/Controllers/TournamentController.php
round category select
[alttp.git] / app / Http / Controllers / TournamentController.php
index e2fbe941a31b6b2b705b1e35c69724e495351191..7912cda36c95b817c2d6cdbf1fdc1b7c9a416449 100644 (file)
@@ -63,8 +63,12 @@ class TournamentController extends Controller
        public function discordSettings(Request $request, Tournament $tournament) {
                $this->authorize('update', $tournament);
                $validatedData = $request->validate([
+                       'round_category' => 'string|nullable',
                        'round_template' => 'string|nullable',
                ]);
+               if (array_key_exists('round_category', $validatedData)) {
+                       $tournament->discord_round_category = $validatedData['round_category'];
+               }
                if (array_key_exists('round_template', $validatedData)) {
                        $tournament->discord_round_template = $validatedData['round_template'];
                }