Permalink
Browse files

Use window.getComputedStyle to prevent breaking jsdom/node.js . Fixes…

… #12235
  • Loading branch information...
rwaldron committed Aug 10, 2012
1 parent 77412e0 commit 3722aef8be5d31a7dbf3de6998cdf249081f028c
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/css.js
@@ -279,11 +279,11 @@ jQuery.extend({
});

// NOTE: To any future maintainer, we've used both window.getComputedStyle

This comment has been minimized.

@staabm

staabm Aug 11, 2012

Contributor

As of now the Comment is bogus

// and getComputedStyle here to produce a better gzip size
// because jsdom on node.js will break without it.
if ( window.getComputedStyle ) {
curCSS = function( elem, name ) {
var ret, width, minWidth, maxWidth,
computed = getComputedStyle( elem, null ),
computed = window.getComputedStyle( elem, null ),
style = elem.style;

if ( computed ) {

0 comments on commit 3722aef

Please sign in to comment.