mirror of
https://github.com/cocos/cocos4.git
synced 2026-12-01 07:42:38 +08:00
Merge pull request #564 from jareguo/master
should not create new callstack for cc._throw
This commit is contained in:
+3
-2
@@ -403,7 +403,8 @@ cc._initDebugSetting = function (mode) {
|
||||
locLog(cc.js.formatStr.apply(cc, arguments));
|
||||
};
|
||||
}
|
||||
} else if(console && console.log.apply){//console is null when user doesn't open dev tool on IE9
|
||||
}
|
||||
else if(console && console.log.apply){//console is null when user doesn't open dev tool on IE9
|
||||
//log to console
|
||||
|
||||
// For JSB
|
||||
@@ -495,7 +496,7 @@ cc._initDebugSetting = function (mode) {
|
||||
};
|
||||
}
|
||||
}
|
||||
cc._throw = function (error) {
|
||||
cc._throw = CC_EDITOR ? Editor.error : function (error) {
|
||||
cc.error(error.stack || error);
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user