Skip to content

Commit b875b96

Browse files
committed
Avoid 'invalid argument' on IE10.
1 parent 6b26010 commit b875b96

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

matchMedia.addListener.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*! matchMedia() polyfill addListener/removeListener extension. Author & copyright (c) 2012: Scott Jehl. Dual MIT/BSD license */
22
(function(){
33
// monkeypatch unsupported addListener/removeListener with polling
4-
if( !window.matchMedia( "" ).addListener ){
4+
if( !window.matchMedia("only screen").addListener ){
55
var oldMM = window.matchMedia;
66

77
window.matchMedia = function( q ){

0 commit comments

Comments
 (0)