From bdc34d7700744a2d58320d6d40fca37b76331697 Mon Sep 17 00:00:00 2001 From: portix Date: Tue, 5 Mar 2013 00:44:46 +0100 Subject: Don't use global formData object for onRead/onWrite in formfiller --- extensions/formfiller | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'extensions/formfiller') diff --git a/extensions/formfiller b/extensions/formfiller index 10b2474a..6fc67e04 100644 --- a/extensions/formfiller +++ b/extensions/formfiller @@ -282,10 +282,11 @@ function onRead() { return null; } function getFormData(callback) //{{{ { var stat, ret; + var data; if (config.useGPG) { - if (formData !== null) - return formData; + if (data !== null) + return data; if ((formData = exports.onRead())) return JSON.parse(formData.replace(/\\"/g, '"')); @@ -318,8 +319,8 @@ function getFormData(callback) //{{{ { try { - if ((formData = onRead())) - return JSON.parse(formData); + if ((data = onRead())) + return JSON.parse(data); else return JSON.parse(io.read(config.formData)); } -- cgit v1.2.3