From afd758f509d48f310503cc842d161fcfac93b164 Mon Sep 17 00:00:00 2001 From: Simon Kornblith Date: Thu, 24 Jun 2010 09:54:46 +0000 Subject: [PATCH] support additional parameters in integration pipe (these are not urgent, and i don't actually plan on using them at the present, but they might be a good idea) --- chrome/content/zotero/xpcom/integration.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/chrome/content/zotero/xpcom/integration.js b/chrome/content/zotero/xpcom/integration.js index 24b3265763..9cfe5d6dc0 100644 --- a/chrome/content/zotero/xpcom/integration.js +++ b/chrome/content/zotero/xpcom/integration.js @@ -123,9 +123,9 @@ Zotero.Integration = new function() { fifoStream.readLine(line); fifoStream.close(); - var spaceIndex = line.value.indexOf(" "); - var agent = line.value.substr(0, spaceIndex); - var cmd = line.value.substr(spaceIndex+1); + var parts = line.value.split(" "); + var agent = parts[0]; + var cmd = parts[1]; if(agent == "Zotero" && cmd == "shutdown") return; main.dispatch(new mainThread(agent, cmd), background.DISPATCH_NORMAL); }