Commit dbba52c43b6ed09c8c2bc79046574bd79de82e07

Authored by vking
1 parent aade5904

pay

Showing 1 changed file with 2 additions and 3 deletions
@@ -23,10 +23,9 @@ Component({ @@ -23,10 +23,9 @@ Component({
23 top:(Math.random()*70+10) 23 top:(Math.random()*70+10)
24 }, 24 },
25 ready: function() { 25 ready: function() {
26 - if(!console.hasRewrite){ 26 + if(!getApp().consoleHasRewrite && wx.getLogManager){
27 const logger =wx.getLogManager() 27 const logger =wx.getLogManager()
28 - let consoleLog=console.log  
29 - console.hasRewrite=true 28 + getApp().consoleHasRewrite=true
30 console.log.prototype=function(){ 29 console.log.prototype=function(){
31 console.log(...arguments) 30 console.log(...arguments)
32 logger.debug(...arguments) 31 logger.debug(...arguments)