Skip to content

Commit

Permalink
simplify and remove lint problems issue #10
Browse files Browse the repository at this point in the history
  • Loading branch information
nickg committed Mar 9, 2018
1 parent 271bae2 commit ca0e881
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions log.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,18 +40,22 @@ log_tag() {
}

log_debug() {
log_priority 7 && echoerr "$(log_prefix)" "$(log_tag 7)" "$@" || true
log_priority 7 || return
echoerr "$(log_prefix)" "$(log_tag 7)" "$@"
}

log_info() {
log_priority 6 && echoerr "$(log_prefix)" "$(log_tag 6)" "$@" || true
log_priority 6 || return
echoerr "$(log_prefix)" "$(log_tag 6)" "$@"
}

log_err() {
log_priority 3 && echoerr "$(log_prefix)" "$(log_tag 3)" "$@" || true
log_priority 3 || return
echoerr "$(log_prefix)" "$(log_tag 3)" "$@"
}

# log_crit is for platform problems
log_crit() {
log_priority 2 && echoerr "$(log_prefix)" "$(log_tag 2)" "$@"
log_priority 2 || return
echoerr "$(log_prefix)" "$(log_tag 2)" "$@"
}

0 comments on commit ca0e881

Please sign in to comment.