[Opensrf-commits] r2031 - trunk/src/javascript (erickson)

svn at svn.open-ils.org svn at svn.open-ils.org
Mon Oct 11 22:58:19 EDT 2010


Author: erickson
Date: 2010-10-11 22:58:16 -0400 (Mon, 11 Oct 2010)
New Revision: 2031

Modified:
   trunk/src/javascript/opensrf.js
Log:
when we add xhr responses onto the end of the queue, stash the original session as well, otherwise we're attempting to ask a session questions about requests it's not tracking

Modified: trunk/src/javascript/opensrf.js
===================================================================
--- trunk/src/javascript/opensrf.js	2010-10-07 12:57:56 UTC (rev 2030)
+++ trunk/src/javascript/opensrf.js	2010-10-12 02:58:16 UTC (rev 2031)
@@ -256,12 +256,12 @@
 
     // push the latest responses onto the end of the inbound message queue
     for(var i = 0; i < osrf_msgs.length; i++)
-        OpenSRF.Stack.queue.push({msg : osrf_msgs[i], callbacks : callbacks});
+        OpenSRF.Stack.queue.push({msg : osrf_msgs[i], callbacks : callbacks, ses : ses});
 
     // continue processing responses, oldest to newest
     while(OpenSRF.Stack.queue.length) {
         var data = OpenSRF.Stack.queue.shift();
-        OpenSRF.Stack.handle_message(ses, data.msg, data.callbacks);
+        OpenSRF.Stack.handle_message(data.ses, data.msg, data.callbacks);
     }
 }
 



More information about the opensrf-commits mailing list