Advertisement
Guest User

Untitled

a guest
Aug 23rd, 2019
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. import con from '../config.js'
  2. console.log = (function(oriLogFunc) {
  3. return function() {
  4. //判断配置文件是否开启日志调试
  5. if (con.getLogDebug) {
  6. try {
  7. oriLogFunc.call(console, ...arguments);
  8. } catch (e) {
  9. console.error('console.log error', e);
  10. }
  11. }
  12. }
  13. })(console.log);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement