From 56d22ff9adbe84f292f4e55387feee7029e3e7bd Mon Sep 17 00:00:00 2001 From: Frederic Junod Date: Sun, 22 Jan 2012 14:21:17 +0100 Subject: [PATCH] coding standards: replace 'new Array()' with '[]' --- lib/OpenLayers/Format/CSWGetRecords/v2_0_2.js | 4 ++-- lib/OpenLayers/Layer/FixedZoomLevels.js | 2 +- lib/OpenLayers/Layer/Text.js | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/OpenLayers/Format/CSWGetRecords/v2_0_2.js b/lib/OpenLayers/Format/CSWGetRecords/v2_0_2.js index b1fece8112..4a5aa18491 100644 --- a/lib/OpenLayers/Format/CSWGetRecords/v2_0_2.js +++ b/lib/OpenLayers/Format/CSWGetRecords/v2_0_2.js @@ -255,7 +255,7 @@ OpenLayers.Format.CSWGetRecords.v2_0_2 = OpenLayers.Class(OpenLayers.Format.XML, "*": function(node, obj) { var name = node.localName || node.nodeName.split(":").pop(); if (!(OpenLayers.Util.isArray(obj[name]))) { - obj[name] = new Array(); + obj[name] = []; } var dc_element = {}; var attrs = node.attributes; @@ -273,7 +273,7 @@ OpenLayers.Format.CSWGetRecords.v2_0_2 = OpenLayers.Class(OpenLayers.Format.XML, "*": function(node, obj) { var name = node.localName || node.nodeName.split(":").pop(); if (!(OpenLayers.Util.isArray(obj[name]))) { - obj[name] = new Array(); + obj[name] = []; } obj[name].push(this.getChildValue(node)); } diff --git a/lib/OpenLayers/Layer/FixedZoomLevels.js b/lib/OpenLayers/Layer/FixedZoomLevels.js index 47ad10e0d3..ec75499e5f 100644 --- a/lib/OpenLayers/Layer/FixedZoomLevels.js +++ b/lib/OpenLayers/Layer/FixedZoomLevels.js @@ -77,7 +77,7 @@ OpenLayers.Layer.FixedZoomLevels = OpenLayers.Class({ */ initResolutions: function() { - var props = new Array('minZoomLevel', 'maxZoomLevel', 'numZoomLevels'); + var props = ['minZoomLevel', 'maxZoomLevel', 'numZoomLevels']; for(var i=0, len=props.length; i