From f3b82ba7c3b560ba93c5bc7641a2fdb923965bfc Mon Sep 17 00:00:00 2001 From: Venix <30481900+venix12@users.noreply.github.com> Date: Tue, 30 Jan 2024 12:03:31 +0100 Subject: [PATCH] misc review fixes --- app/Http/Controllers/ContestEntriesController.php | 2 +- resources/js/stores/contest-judge-store.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/ContestEntriesController.php b/app/Http/Controllers/ContestEntriesController.php index 0c35b499d3c..6ffb2e0f6e4 100644 --- a/app/Http/Controllers/ContestEntriesController.php +++ b/app/Http/Controllers/ContestEntriesController.php @@ -71,7 +71,7 @@ public function judgeVote($id) $params = get_params(request()->all(), null, [ 'scores:array', 'comment', - ]); + ], ['null_missing' => true]); $scoresByCategoryId = collect($params['scores']) ->keyBy('contest_scoring_category_id'); diff --git a/resources/js/stores/contest-judge-store.ts b/resources/js/stores/contest-judge-store.ts index 95b0b42b762..0cd811a739b 100644 --- a/resources/js/stores/contest-judge-store.ts +++ b/resources/js/stores/contest-judge-store.ts @@ -23,7 +23,7 @@ export default class ContestJudgeStore { @action updateWithJson(data: ContestJsonForStore) { - data.entries?.forEach((json) => { + data.entries.forEach((json) => { const entry = new ContestEntry(json); this.entries.set(entry.id, entry); });