From 54abf987f6d5a8a7a3225729e47d9c5ca5281b9b Mon Sep 17 00:00:00 2001 From: Urban Müller Date: Wed, 26 Jun 2013 13:16:03 +0000 Subject: fix for "use strict" --- itjs/state.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'itjs') diff --git a/itjs/state.js b/itjs/state.js index 19f7438..81156f1 100644 --- a/itjs/state.js +++ b/itjs/state.js @@ -108,7 +108,7 @@ store_state: function() { var value = this[key], type = typeof(value); if (!key.match(/^it_/) && type.match(/boolean|number|string/)) - ser[ser.length] = key + ':' + ((type == 'string') ? "'" + value.replace(/([\\'])/g, '\\\1') + "'" : value); + ser[ser.length] = key + ':' + ((type == 'string') ? "'" + value.replace(/([\\'])/g, '\\$1') + "'" : value); // escape backslashes and single quotes } this.it_history_field.value = ser.join(','); -- cgit v1.2.3