[Pkg-javascript-commits] [dojo] 06/87: Copying dojo/query change from [26967] to 1.7 branch, fixes #14278 !strict

David Prévot taffit at moszumanska.debian.org
Thu Aug 21 17:39:13 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to annotated tag 1.7.5
in repository dojo.

commit c0b8240e883615f451298467a9df48b1deda8bf8
Author: Kris Zyp <kriszyp at gmail.com>
Date:   Thu Nov 17 17:53:05 2011 +0000

    Copying dojo/query change from [26967] to 1.7 branch, fixes #14278 !strict
    
    git-svn-id: http://svn.dojotoolkit.org/src/branches/1.7/dojo@27042 560b804f-0ae3-0310-86f3-f6aa0a117693
---
 query.js | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/query.js b/query.js
index 2f1aeab..4685e81 100644
--- a/query.js
+++ b/query.js
@@ -1,4 +1,5 @@
-define(["./_base/kernel", "./has", "./on", "./_base/array", "./_base/lang", "./selector/_loader", "./selector/_loader!default"], function(dojo, has, on, array, lang, loader, defaultEngine){
+define(["./_base/kernel", "./has", "./dom", "./on", "./_base/array", "./_base/lang", "./selector/_loader", "./selector/_loader!default"],
+	function(dojo, has, dom, on, array, lang, loader, defaultEngine){
 "use strict";
 
 	has.add("array-extensible", function(){
@@ -200,7 +201,7 @@ define(["./_base/kernel", "./has", "./on", "./_base/array", "./_base/lang", "./s
 		nodeArray._NodeListCtor = function(array){
 			// call without new operator to preserve back-compat behavior
 			return nl(array);
-		}
+		};
 		return nodeArray;
 	};
 	
@@ -647,7 +648,7 @@ function queryForEngine(engine, NodeList){
 		//		entire document by default but optionally taking a node to scope
 		//		the search by. Returns an instance of dojo.NodeList.
 		if(typeof root == "string"){
-			root = dojo.byId(root);
+			root = dom.byId(root);
 			if(!root){
 				return new NodeList([]);
 			}
@@ -669,7 +670,7 @@ function queryForEngine(engine, NodeList){
 		// summary:
 		//		Filters an array of nodes. Note that this does not guarantee to return a dojo.NodeList, just an array.
 		return query(selector, root).filter(function(node){
-			return dojo.indexOf(nodes, node) > -1;
+			return array.indexOf(nodes, node) > -1;
 		});
 	};
 	if(typeof engine != "function"){

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/dojo.git



More information about the Pkg-javascript-commits mailing list