mirror of
https://github.com/discourse/discourse.git
synced 2024-11-27 02:53:41 +08:00
FIX: (for IE9) if console.log
doesn't exist, make it an noop.
This commit is contained in:
parent
1ed34be1b9
commit
df8880a71a
10
app/assets/javascripts/discourse/initializers/ie9-hax.js.es6
Normal file
10
app/assets/javascripts/discourse/initializers/ie9-hax.js.es6
Normal file
|
@ -0,0 +1,10 @@
|
|||
export default {
|
||||
name: 'ie9-hacks',
|
||||
initialize: function() {
|
||||
if (!window) { return; }
|
||||
|
||||
// IE9 does not support a console object unless the developer tools are open
|
||||
if (!window.console) { window.console = {}; }
|
||||
if (!window.console.log) { window.console.log = Ember.K; }
|
||||
}
|
||||
};
|
Loading…
Reference in New Issue
Block a user