Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Issue 5841: Short tag of element rep treats class=" a" as having a cl…

  • Loading branch information...
commit f3c285c21b72bb0cca6169f1cbaede89c416c907 1 parent 80e14eb
@simonlindholm simonlindholm authored
Showing with 3 additions and 5 deletions.
  1. +3 −5 extension/content/firebug/chrome/reps.js
View
8 extension/content/firebug/chrome/reps.js
@@ -671,7 +671,7 @@ FirebugReps.Arr = domplate(Firebug.Rep,
highlightObject: function(object, context, target)
{
- // Highlighting huge amount of elements on the page can cause sericous performance
+ // Highlighting huge amount of elements on the page can cause serious performance
// problems (see issue 4736). So, avoid highlighting if the number of elements in
// the array exceeds specified limit.
var arr = this.getRealObject(object, context);
@@ -907,14 +907,12 @@ FirebugReps.Element = domplate(Firebug.Rep,
{
try
{
- return elt.getAttribute("class")
- ? ("." + elt.getAttribute("class").split(" ")[0])
- : "";
+ return elt.classList.length > 0 ? ("." + elt.classList[0]) : "";
}
catch (err)
{
+ return "";
}
- return "";
},
getValue: function(elt)
Please sign in to comment.
Something went wrong with that request. Please try again.