Skip to content

Commit

Permalink
refactor(CalendarSelect): respond to PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
philip-cline committed Nov 22, 2023
1 parent 212ef3e commit 96bff40
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/editor/components/timetable/CalendarSelect.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ export default class CalendarSelect extends Component<Props> {
_getOptions = (): Array<CalendarOption> => {
const {activePattern, calendars, exceptionBasedCalendars, tripCounts, trips} = this.props
const patternId = activePattern && activePattern.patternId
let calendarOptions: Array<CalendarOption> = calendars && activePattern
const calendarBasedOptions: Array<CalendarOption> = calendars && activePattern
? calendars
.map(calendar => ({
label: calendar.description || calendar.service_id,
Expand All @@ -129,7 +129,7 @@ export default class CalendarSelect extends Component<Props> {
}))

// $FlowFixMe: we need two types of options
calendarOptions = calendarOptions.concat(exceptionBasedCalendarOptions)
const calendarOptions = calendarBasedOptions.concat(exceptionBasedCalendarOptions)

return calendarOptions
.sort((a, b) => {
Expand Down

0 comments on commit 96bff40

Please sign in to comment.