[gnome-maps] resrobot: Fix availability of "scroll" parameters



commit 4eb1d513790fe6c1b49a56502ad310daa7d721fd
Author: Marcus Lundblad <ml update uu se>
Date:   Thu Nov 14 22:19:45 2019 +0100

    resrobot: Fix availability of "scroll" parameters
    
    Check availability of either "scroll forward" or
    "scroll backwards" referens parameters in the
    previous response depending on if "arrive by"
    is set or not when searching for later/earlier
    options. Fixes a null when serializing HTTP
    parameters, resulting in infinite spinner.

 src/transitplugins/resrobot.js | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/src/transitplugins/resrobot.js b/src/transitplugins/resrobot.js
index 5d38bb2b..20493d42 100644
--- a/src/transitplugins/resrobot.js
+++ b/src/transitplugins/resrobot.js
@@ -128,7 +128,8 @@ var Resrobot = class Resrobot {
     fetchMoreResults() {
         this._extendPrevious = true;
 
-        if (!this._scrF && !this._scrB)
+        if ((!this._scrF && !this._query.arriveBy) ||
+            (!this._scrB && this._query.arriveBy))
             this._noRouteFound();
         else
             this._fetchResults();


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]