Permalink
Browse files

Fixes #506 IE9 mq issue and failing test in IE6/7

  • Loading branch information...
1 parent ceea6ab commit c9828ee23f983aec511400b1ea7dd611e18e3188 @ryanseddon ryanseddon committed Feb 23, 2012
Showing with 2 additions and 2 deletions.
  1. +1 −1 modernizr.js
  2. +1 −1 test/js/unit.js
View
@@ -110,7 +110,7 @@ window.Modernizr = (function( window, document, undefined ) {
div.id = mod;
// IE6 will false positive on some tests due to the style element inside the test div somehow interfering offsetHeight, so insert it into body or fakebody.
// Opera will act all quirky when injecting elements in documentElement when page is served as xml, needs fakebody too. #270
- fakeBody.innerHTML += style;
+ (body ? div : fakeBody).innerHTML += style;
fakeBody.appendChild(div);
if(!body){
//avoid crashing IE8, if background image is used
View
@@ -393,7 +393,7 @@ test('Modernizr.testStyles()',function(){
equals(typeof Modernizr.testStyles, 'function','Modernizr.testStyles() is a function');
- var style = '#modernizr{ width: 9px; height: 4px; color: papayawhip; }';
+ var style = '#modernizr{ width: 9px; height: 4px; font-size: 0; color: papayawhip; }';
Modernizr.testStyles(style, function(elem, rule){
equals(style, rule, 'rule passsed back matches what i gave it.')

0 comments on commit c9828ee

Please sign in to comment.