From: miker Date: Fri, 3 Sep 2010 17:30:36 +0000 (+0000) Subject: we should really just use for(;;) for arguments X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=959b6e4a15d01b5a41c27af9ab3007f66c36db41;p=contrib%2FConifer.git we should really just use for(;;) for arguments git-svn-id: svn://svn.open-ils.org/ILS/trunk@17476 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/web/js/dojo/MARC/Field.js b/Open-ILS/web/js/dojo/MARC/Field.js index 9694c3840d..7242a8945b 100644 --- a/Open-ILS/web/js/dojo/MARC/Field.js +++ b/Open-ILS/web/js/dojo/MARC/Field.js @@ -47,7 +47,7 @@ if(!dojo._hasResource["MARC.Field"]) { }, addSubfields : function () { - for (var i in arguments) { + for (var i = 0; i < arguments.length; i++) { var code = arguments[i]; var value = arguments[++i]; this.subfields.push( [ code, value ] ); diff --git a/Open-ILS/web/js/dojo/MARC/Record.js b/Open-ILS/web/js/dojo/MARC/Record.js index 635015f281..5c9fb9d19b 100644 --- a/Open-ILS/web/js/dojo/MARC/Record.js +++ b/Open-ILS/web/js/dojo/MARC/Record.js @@ -68,7 +68,7 @@ if(!dojo._hasResource["MARC.Record"]) { insertOrderedFields : function () { var me = this; - for ( var i in arguments ) { // arguments is special, and for..in is correct + for (var i = 0; i < arguments.length; i++) { var f = arguments[i]; var done = false; for (var j = 0; j < this.fields.length; j++) {