BUG Fix rewriteHashlinks in TabSet

As per commit 3478813, check for presence of href before matching
This commit is contained in:
Marcus Nyeholt 2012-12-04 15:59:33 +11:00
parent 34788130ef
commit 1a4b245e84

View File

@ -24,6 +24,8 @@
*/
rewriteHashlinks: function() {
$(this).find('ul a').each(function() {
if (!$(this).attr('href')) return;
var matches = $(this).attr('href').match(/#.*/);
if(!matches) return;
$(this).attr('href', document.location.href.replace(/#.*/, '') + matches[0]);