Pārlūkot izejas kodu

root fixes for getElementsByName

Ivan Asmer 8 gadi atpakaļ
vecāks
revīzija
d4f281926c
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      static/nb.js

+ 1 - 1
static/nb.js

@@ -24,7 +24,7 @@ function nbInit(a,b){
             items = root.querySelectorAll("#" + selector); 
         }
         items     = items[0]     ? items :  root.querySelectorAll(selector);
-        items     = items.length ? items :  root === document ? root.getElementsByName(selector) ? root.querySelectorAll("['name'='" + selector + "']"); 
+        items     = items.length ? items :  root === document ? root.getElementsByName(selector) : root.querySelectorAll("['name'='" + selector + "']"); 
         items     = items.length ? items :  root.getElementsByClassName(selector); 
         return items;
     }