From 7f9e637d8b2a7997448ae43d8d677dff52a88886 Mon Sep 17 00:00:00 2001 From: Ryan Tanenholz <44756861+RockCrafts@users.noreply.github.com> Date: Wed, 12 Feb 2025 00:49:07 -0500 Subject: [PATCH] :bug: Fixed a issue with Queue settings which did not allow users to toggle some settings --- .../InstructorQueuePage/QueueFormFields.tsx | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/frontend/components/Course/InstructorQueuePage/QueueFormFields.tsx b/frontend/components/Course/InstructorQueuePage/QueueFormFields.tsx index b5925f61..a40bf964 100644 --- a/frontend/components/Course/InstructorQueuePage/QueueFormFields.tsx +++ b/frontend/components/Course/InstructorQueuePage/QueueFormFields.tsx @@ -172,11 +172,6 @@ const QueueFormFields = ({ } setInput({ ...input }); }; - - const handlePinInputChange = (e, { checked }) => { - input.pinEnabled = checked; - setInput({ ...input }); - }; /* PROPS UPDATE */ return ( @@ -246,7 +241,12 @@ const QueueFormFields = ({ id="pin-toggle" toggle disabled={loading} - onChange={handlePinInputChange} + onClick={() => + setInput({ + ...input, + pinEnabled: !input.pinEnabled, + }) + } /> @@ -261,9 +261,9 @@ const QueueFormFields = ({ name="rateLimitEnabled" id="rate-limit-toggle" toggle - defaultChecked={input.rateLimitEnabled} + checked={input.rateLimitEnabled} label="Enable queue rate-limiting" - onChange={() => + onClick={() => setInput({ ...input, rateLimitEnabled: !input.rateLimitEnabled,