From 33501c44eafb9f51d700539b2ab6ff6c94ee2565 Mon Sep 17 00:00:00 2001 From: Luke Slater Date: Wed, 20 Jun 2012 08:17:46 +0100 Subject: [PATCH] Add braces around withAll --- snippets.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/snippets.js b/snippets.js index cfcfae3..762a0bb 100644 --- a/snippets.js +++ b/snippets.js @@ -165,9 +165,11 @@ Object.prototype.isArray = function(obj) { }; Object.prototype.withAll = function(fun) { - for(key in this) - if(this.hasOwnProperty(key)) + for(key in this) { + if(this.hasOwnProperty(key)){ fun(key, this[key]); + } + } }; Object.prototype.length = function() {