diff options
author | Marcus Lundblad <ml@update.uu.se> | 2019-10-19 23:16:38 +0200 |
---|---|---|
committer | Marcus Lundblad <ml@update.uu.se> | 2019-10-28 22:16:51 +0100 |
commit | 0d853d6f42b8f907774dd167905f4a7908d70b30 (patch) | |
tree | b076522a61bfe356b90988f820c7ed7be3cefffb | |
parent | b401c06f50ff69849f858cc482633682910c5176 (diff) | |
download | gnome-maps-wip/mlundblad/transit-tweaks.tar.gz |
resrobot: Use transit tweakswip/mlundblad/transit-tweaks
-rw-r--r-- | src/transitplugins/resrobot.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/transitplugins/resrobot.js b/src/transitplugins/resrobot.js index f1aedb6d..19048773 100644 --- a/src/transitplugins/resrobot.js +++ b/src/transitplugins/resrobot.js @@ -36,6 +36,7 @@ const GraphHopperTransit = imports.graphHopperTransit; const HTTP = imports.http; const HVT = imports.hvt; const TransitPlan = imports.transitPlan; +const TransitTweaks = imports.transitTweaks; const Utils = imports.utils; const BASE_URL = 'https://api.resrobot.se'; @@ -97,6 +98,7 @@ var Resrobot = class Resrobot { this._query = Application.routeQuery; this._key = params.key; this._tz = GLib.TimeZone.new(NATIVE_TIMEZONE); + this._tweaks = new TransitTweaks.TransitTweaks({ name: 'resrobot' }); if (!this._key) throw new Error('missing key'); @@ -213,7 +215,9 @@ var Resrobot = class Resrobot { // store the back and forward references from the result this._scrB = result.scrB; this._scrF = result.scrF; - this._processItineraries(itineraries); + this._tweaks.applyTweaks(itineraries, () => { + this._processItineraries(itineraries) + }); } else { this._noRouteFound(); } |