How to use the getLevel function from loglevel

Find comprehensive JavaScript loglevel.getLevel code examples handpicked from public code repositorys.

620
621
622
623
624
625
626
627
628
629
    phoneTime = timePM;
  }
}

// something has gone wrong if no info was matched, save image for later analysis
if (debugFlag || ((!phoneTime || (phoneTime && !phoneTime.isValid())) && log.getLevel() === log.levels.DEBUG)) {
  log.debug('Phone Time: ', id, value.text);
  if (value.image) {
    value.image.write(debugImagePath);
  }
fork icon20
star icon15
watch icon0

+ 5 other calls in file

61
62
63
64
65
66
67
68
69
70
function setLevel (level) {
  mlog.setLevel(level)
}

function getLevel () {
  return mlog.getLevel()
}
function setup () {
  colors = {
    TRACE: chalk.magenta,
fork icon0
star icon2
watch icon2

70
71
72
73
74
75
76
77
78
79
    log.info(`- If you're stuck, get help with "${'git-quest help'.green}"`);
}

setupGitInterceptor() {
    git.outputHandler((command, stdout, stderr) => {
        if (command && log.getLevel() < log.levels.INFO) {
            log.debug(command)
        }
    });
}
fork icon0
star icon0
watch icon0