Skip to content

Commit

Permalink
try to fix bouncing on the mutation
Browse files Browse the repository at this point in the history
  • Loading branch information
AaDalal committed May 12, 2024
1 parent d2609c8 commit 1ec266a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion frontend/degree-plan/components/FourYearPlan/Semester.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ const FlexSemester = ({
const prev_rules = fulfillments.find((fulfillment) => fulfillment.full_code === course.full_code)?.rules || [];
createOrUpdateFulfillment({ rules: [...prev_rules, course.rule_id], semester }, course.full_code)
.then((fulfillment) => {
if (fulfillment?.course) createOrUpdateFulfillment({ try_rules: getExpectedDoubleCounts(fulfillment.course) }, course.full_code);
if (fulfillment?.course) createOrUpdateFulfillment({ rules: fulfillment.rules, try_rules: getExpectedDoubleCounts(fulfillment.course) }, course.full_code);
return undefined;
})
}
Expand Down
2 changes: 1 addition & 1 deletion frontend/degree-plan/components/Requirements/Rule.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ const RuleComponent = (ruleTree : RuleTree) => {
course.full_code,
)
.then((fulfillment) => {
if (fulfillment?.course) createOrUpdateFulfillment({ try_rules: getExpectedDoubleCounts(fulfillment.course) }, course.full_code);
if (fulfillment?.course) createOrUpdateFulfillment({ rules: fulfillment.rules, try_rules: getExpectedDoubleCounts(fulfillment.course) }, course.full_code);
return undefined;
})
return undefined;
Expand Down

0 comments on commit 1ec266a

Please sign in to comment.