diff --git a/platform/firefox/vapi-background.js b/platform/firefox/vapi-background.js index e8a8d28b2..d257f26dc 100644 --- a/platform/firefox/vapi-background.js +++ b/platform/firefox/vapi-background.js @@ -195,6 +195,9 @@ vAPI.storage = { var key, values = [], placeholders = []; for ( key in details ) { + if ( !details.hasOwnProperty(key) ) { + continue; + } values.push(key); values.push(JSON.stringify(details[key])); placeholders.push('?, ?'); diff --git a/platform/safari/vapi-background.js b/platform/safari/vapi-background.js index 02b62f863..6769855fa 100644 --- a/platform/safari/vapi-background.js +++ b/platform/safari/vapi-background.js @@ -126,6 +126,9 @@ vAPI.storage = { set: function(details, callback) { for ( var key in details ) { + if ( !details.hasOwnProperty(key) ) { + continue; + } this._storage.setItem(key, JSON.stringify(details[key])); }