diff --git a/__tests__/components/viewers/__snapshots__/stop-schedule-viewer.ts.snap b/__tests__/components/viewers/__snapshots__/stop-schedule-viewer.ts.snap index 3fecffc8a..8b0b694f1 100644 --- a/__tests__/components/viewers/__snapshots__/stop-schedule-viewer.ts.snap +++ b/__tests__/components/viewers/__snapshots__/stop-schedule-viewer.ts.snap @@ -100,8 +100,8 @@ exports[`components > viewers > stop viewer should render with initial stop id a } > Math.round(meters * 0.000621371 * 100) / 100 -const milesToMeters = (miles) => miles / 0.000621371 - /** * Converts a new TransportMode object to legacy style underscore qualifier */ @@ -80,7 +74,7 @@ class AdvancedOptions extends Component { this.props.findRoutesIfNeeded() } - componentDidUpdate(prevProps) { + componentDidUpdate() { const { routes } = this.props // Once routes are available, map them to the route options format. const routeOptions = Object.values(routes).map(this.routeToOption) @@ -113,17 +107,6 @@ class AdvancedOptions extends Component { return bannedRoutes && bannedRoutes.find((o) => o.value === option.value) } - getDistanceStep = (distanceInMeters) => { - // Determine step for max walk/bike based on current value. Increment by a - // quarter mile if dealing with small values, whatever number will round off - // the number if it is not an integer, or default to one mile. - return metersToMiles(distanceInMeters) <= 2 - ? '.25' - : metersToMiles(distanceInMeters) % 1 !== 0 - ? `${metersToMiles(distanceInMeters) % 1}` - : '1' - } - _onSubModeChange = (changedMode) => { // Get previous transit modes from state and all modes from query. const transitModes = [...this.state.transitModes] @@ -157,6 +140,7 @@ class AdvancedOptions extends Component { _setCustomModeSetting = (option) => { this.props.setUrlSearch(option) + this.props.setQueryParam(option) } /**