From 4bf6664d6b28bfab7d1d220a40e54be0ad0ebfe2 Mon Sep 17 00:00:00 2001 From: Deathamns Date: Sun, 9 Nov 2014 11:59:34 +0100 Subject: [PATCH] Fix double definition of `length` property in uDom The `length` property of `DOMList` couldn't be re-defined, because earlier an Object.defineProperty was used on the object without a setter. --- src/js/udom.js | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/src/js/udom.js b/src/js/udom.js index 8b59e4208..4df00f674 100644 --- a/src/js/udom.js +++ b/src/js/udom.js @@ -19,8 +19,6 @@ Home: https://github.com/gorhill/uBlock */ -/******************************************************************************/ - /* exported uDom */ 'use strict'; @@ -42,18 +40,6 @@ var DOMList = function() { /******************************************************************************/ -Object.defineProperty( - DOMList.prototype, - 'length', - { - get: function() { - return this.nodes.length; - } - } -); - -/******************************************************************************/ - var DOMListFactory = function(selector, context) { var r = new DOMList(); if ( typeof selector === 'string' ) {