Permalink
Browse files

Using established id var instead of finding (potentially undefined) a…

…ttribute again.
  • Loading branch information...
1 parent ce4724c commit e4cfe12a07f39f7233063a8cea0f19612b3ed53d @nathancolgate nathancolgate committed Apr 25, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 js/jquery.fn.gantt.js
View
@@ -49,7 +49,7 @@
id = id ? id : "";
var si = id.indexOf("-") + 1;
cd = cd.getFullYear() + "-" + cd.getDayForWeek().getWeekOfYear();
- var ed = $(a).attr("id").substring(si, $(a).attr("id").length);
+ var ed = id.substring(si, id.length);
return cd === ed;
}
});
@@ -61,7 +61,7 @@
var id = $(a).attr("id");
id = id ? id : "";
var si = id.indexOf("-") + 1;
- var ed = $(a).attr("id").substring(si, $(a).attr("id").length);
+ var ed = id.substring(si, id.length);
return cd === ed;
}
});

0 comments on commit e4cfe12

Please sign in to comment.