Skip to content

Commit

Permalink
fix(apps/frontend-manage): sample solution for free text questions sh…
Browse files Browse the repository at this point in the history
…ould only be required conditionally (#4371)
  • Loading branch information
sjschlapbach authored Nov 12, 2024
1 parent e87944e commit 9eef146
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ function useOptionsSchemaFreeText() {
.required(t('manage.formErrors.enterSolution'))
.min(1, t('manage.formErrors.enterSolution'))
)
.nullable()
.when('hasSampleSolution', {
is: true,
then: (schema) =>
Expand Down
2 changes: 0 additions & 2 deletions apps/frontend-manage/src/lib/hooks/useSortingAndFiltering.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ const INITIAL_STATE: FilterSortType = {
}

function reducer(state: FilterSortType, action: ReducerAction): FilterSortType {
console.log(state, action)

switch (action.type) {
case QuestionPoolReducerActionType.TAG_CLICK:
// if the changed tag is untagged
Expand Down

0 comments on commit 9eef146

Please sign in to comment.