[polari] app: Fix filtering of alternate servers



commit c25c0298379b9bbd6237f495d0db60cffb54032a
Author: Florian Müllner <fmuellner gnome org>
Date:   Tue Aug 2 22:42:30 2016 +0200

    app: Fix filtering of alternate servers
    
    When connecting to a server of a predefined network fails, we use
    the list of servers to keep trying. The intention of the code is
    to skip the server that already failed, but as we currently compare
    an object to a string, we end up including it anyway.
    Fix the filtering function to produce the expected result.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=766935

 src/application.js |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/application.js b/src/application.js
index c229e55..3d3ec7c 100644
--- a/src/application.js
+++ b/src/application.js
@@ -394,7 +394,7 @@ const Application = new Lang.Class({
           retry: 0,
           originalNick: account.nickname,
           callback: callback,
-          alternateServers: accountServers.filter(s => s != server)
+          alternateServers: accountServers.filter(s => s.address != server)
         };
 
         this._pendingRequests[roomId] = requestData;


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