From ecd86cf8eee8cf6c5a3b6019b8d98835a60564fa Mon Sep 17 00:00:00 2001 From: Eric Kever Date: Tue, 19 Jul 2011 19:59:09 -0400 Subject: [PATCH] Removed redundancy in newer browsers by using default getElementsByClassName() if it exists. --- javascripts/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javascripts/app.js b/javascripts/app.js index 5a44ec6..13d0746 100644 --- a/javascripts/app.js +++ b/javascripts/app.js @@ -69,7 +69,7 @@ function removeClass(element, name){ } function doFancyExpensiveTabThings(){ - var tabs = getElementsByClassName(document, "ul", "tabs"); + var tabs = (document.getElementsByClassName ? document.getElementsByClassName("tabs") : getElementsByClassName(document, "ul", "tabs")); for(var i = 0, j = tabs.length; i < j; i++){ var tabList = tabs[i].getElementsByTagName('li');