Lazy logging without header

This commit is contained in:
terry-xiaoyu 2018-11-19 10:55:12 +08:00 committed by turtleDeng
parent 82b8047349
commit bc1464a33f
1 changed files with 7 additions and 1 deletions

View File

@ -14,5 +14,11 @@
end).
-else.
%% without header
-define(LOG(Level, Format, Args), logger:log(Level, Format, Args)).
-define(LOG(Level, Format, Args),
begin
(logger:log(Level,#{},#{report_cb =>
fun(_) ->
{(Format), (Args)}
end}))
end).
-endif.