Differ when built on mac?
[pazpar2-moved-to-github.git] / js / pz2.js
index b321e5a..4ff5798 100644 (file)
--- a/js/pz2.js
+++ b/js/pz2.js
@@ -284,13 +284,17 @@ pz2.prototype =
         else
             var start = 0;
 
-             var searchParams = { 
+       var searchParams = { 
           "command": "search",
           "query": this.currQuery, 
           "session": this.sessionID,
           "windowid" : window.name
         };
        
+        if( sort !== undefined ) {
+            this.currentSort = sort;
+           searchParams["sort"] = sort;
+       }
         if (filter !== undefined)
                searchParams["filter"] = filter;
 
@@ -394,7 +398,7 @@ pz2.prototype =
               "sort": this.currentSort, 
               "block": 1,
               "type": this.showResponseType,
-              "windowid" : window.name,
+              "windowid" : window.name
           };
         if (query_state)
           requestParameters["query-state"] = query_state;