From: Thomas Tanghus Date: Sat, 1 Jun 2013 14:47:34 +0000 (+0200) Subject: Forgot typeof condition X-Git-Tag: v6.0.0alpha2~698^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=bfcf113ce7e4293c955fd76e51e4515f29232b94;p=nextcloud-server.git Forgot typeof condition --- diff --git a/core/js/octemplate.js b/core/js/octemplate.js index 352a23c4dc7..e69c6cc56e0 100644 --- a/core/js/octemplate.js +++ b/core/js/octemplate.js @@ -61,7 +61,9 @@ if(typeof this.options.escapeFunction === 'function') { for (var key = 0; key < this.vars.length; key++) { - this.vars[key] = self.options.escapeFunction(this.vars[key]); + if(typeof this.vars[key] === 'string') { + this.vars[key] = self.options.escapeFunction(this.vars[key]); + } } }