File tree 1 file changed +4
-7
lines changed
1 file changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -84,17 +84,14 @@ const JSUtils = {
84
84
85
85
loglevel : 'debug' ,
86
86
87
- dump : ( msg : string , loglevel ?: string ) => {
87
+ dump : function ( msg : string , loglevel ?: string ) {
88
88
const debug = ! ! JSUtils . loglevel ;
89
- // @ts -ignore
90
- const args = Array . prototype . slice . call ( arguments ) ;
91
- let level = args [ args . length - 1 ] ;
92
- const console = window . console ;
93
-
89
+ const { console} = window ;
94
90
if ( debug && ! ! console ) {
91
+ const args = Array . prototype . slice . call ( arguments ) ;
92
+ let level = args [ args . length - 1 ] ;
95
93
if ( level in console ) args . pop ( ) ;
96
94
else level = 'log' ;
97
-
98
95
// workaround for IE9, in which console.log is not an instance of Function
99
96
if ( debug === true || debug === level ) {
100
97
if ( Function . prototype . bind && typeof console . log == 'object' ) {
You can’t perform that action at this time.
0 commit comments