File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -24,13 +24,13 @@ export const departure: IDeparture = {
2424 scheduledDeparture : 51763 ,
2525 serviceDay : 1645480800 ,
2626 stop : stop ,
27+ stops : [ stop ] ,
2728 trip : {
2829 tripHeadsign : 'Helsinki' ,
2930 tripHeadsignfi : 'Helsinki' ,
3031 tripHeadsignsv : 'Helsingfors' ,
3132 tripHeadsignen : 'Helsinki' ,
3233 gtfsId : 'HSL:1234trip' ,
33- stops : [ stop ] ,
3434 route : { alerts : [ ] , shortName : '123' } ,
3535 } ,
3636} ;
Original file line number Diff line number Diff line change @@ -27,7 +27,6 @@ interface ITrip {
2727 tripHeadsignsv : string ;
2828 tripHeadsignen : string ;
2929 route : IRoute ;
30- stops : Array < IStop > ;
3130 gtfsId : string ;
3231}
3332export interface IDeparture {
@@ -44,6 +43,7 @@ export interface IDeparture {
4443 realtime : boolean ;
4544 pickupType : string ;
4645 stop : IStop ;
46+ stops : Array < IStop > ;
4747 combinedPattern ?: string ;
4848 showStopNumber : boolean ;
4949 showVia : boolean ;
@@ -193,12 +193,12 @@ const MonitorRow: FC<IProps> = ({
193193 )
194194 : '' ;
195195 }
196- /* if (departure.pickupType === 'NONE') {
197- const lastStop = departure.trip? .stops?.slice(-1).pop() .gtfsId;
196+ if ( departure . pickupType === 'NONE' ) {
197+ const lastStop = departure . stops [ departure . stops . length - 1 ] . gtfsId ;
198198 if ( departure . stop . gtfsId === lastStop ) {
199- destination = `${t('endStopArrive')}/${t('endStopTerminus ')}`;
199+ destination = `${ t ( 'arriveTerminal ' ) } ` ;
200200 }
201- } */
201+ }
202202
203203 const line = processLine ( departure . trip ?. route . shortName ) ;
204204 if ( destination ?. indexOf ( ' via' ) !== - 1 ) {
You can’t perform that action at this time.
0 commit comments