Skip to content

Commit

Permalink
uses current semester setting instead of hardcoded default
Browse files Browse the repository at this point in the history
  • Loading branch information
mluo24 committed Jul 29, 2023
1 parent 84ef5e8 commit bc2cae7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion backend/functions/src/student/functions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import {
} from '../course/get_course_id'
import { mapDate } from '../course/functions'
import { FirestoreStudent, Student } from '../types'
import { getCurrentSemester } from '../settings/functions'
const courseRef = db.collection('courses')
const studentRef = db.collection('students')

Expand Down Expand Up @@ -104,7 +105,7 @@ export const addStudentSurveyResponse = async (
courseCatalogNames: string[],
surveySubmittable: boolean
) => {
const roster = 'SP23' // Spring 2023
const roster = await getCurrentSemester()

if (!surveySubmittable) {
throw new Error('Survey is Closed')
Expand Down

0 comments on commit bc2cae7

Please sign in to comment.