LiveEventBus icon indicating copy to clipboard operation
LiveEventBus copied to clipboard

怎么关掉日志?

Open Staticzll opened this issue 6 years ago • 2 comments

怎么关掉日志?怎么关掉日志?怎么关掉日志?

Staticzll avatar Nov 07 '19 03:11 Staticzll

升级到1.5.7,使用方法enableLogger(false),详见:https://github.com/JeremyLiao/LiveEventBus/blob/master/docs/config.md

JeremyLiao avatar Nov 08 '19 14:11 JeremyLiao

enableLogger(false) 实测无法关闭,塞入空的 Logger 实现解决该问题

LiveEventBus.config().setLogger(object : Logger {
    override fun log(level: Level?, msg: String?) {
        // do nothing
    }

    override fun log(level: Level?, msg: String?, th: Throwable?) {
        // do nothing
    }
})

sunnyswag avatar Apr 06 '23 06:04 sunnyswag