Software /
code /
clix
Diff
clix.lua @ 70:5e93cfc73444
clix: Fix logging for new Verse
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 12 Feb 2012 20:45:06 +0000 |
parent | 52:95ea1dca92ed |
child | 82:30f85754b1e0 |
line wrap: on
line diff
--- a/clix.lua Sun Feb 12 02:22:58 2012 +0100 +++ b/clix.lua Sun Feb 12 20:45:06 2012 +0000 @@ -58,12 +58,11 @@ io.stderr:write("The specified account (", opts.account or "default", ") wasn't found in the config file\n"); return nil; end - verse.set_logger(opts.verbose and verse.logger() or verse.filter_log({"error"}, verse.logger())); - local conn = verse.new(verse.logger()); + verse.set_log_handler(io.stderr, not opts.verbose and {"error"}); + local conn = verse.new(); for _, plugin in ipairs(plugins or {}) do conn:add_plugin(plugin); end - conn.log.debug = opts.verbose; conn:hook("authentication-failure", function (err) conn:error("Authentication failure ("..(err.condition or "unknown error")..")"..(err.text and (": "..err.text) or "")); conn:close();