Commit 21c2fb57 authored by Him188's avatar Him188

Set defaultLogger initially disabled

parent 0221767a
...@@ -15,10 +15,7 @@ package net.mamoe.mirai.utils.io ...@@ -15,10 +15,7 @@ package net.mamoe.mirai.utils.io
import kotlinx.io.core.* import kotlinx.io.core.*
import kotlinx.io.pool.useInstance import kotlinx.io.pool.useInstance
import net.mamoe.mirai.utils.DefaultLogger import net.mamoe.mirai.utils.*
import net.mamoe.mirai.utils.MiraiDebugAPI
import net.mamoe.mirai.utils.MiraiLogger
import net.mamoe.mirai.utils.withSwitch
import kotlin.contracts.ExperimentalContracts import kotlin.contracts.ExperimentalContracts
import kotlin.contracts.InvocationKind import kotlin.contracts.InvocationKind
import kotlin.contracts.contract import kotlin.contracts.contract
...@@ -28,7 +25,7 @@ import kotlin.jvm.JvmName ...@@ -28,7 +25,7 @@ import kotlin.jvm.JvmName
@MiraiDebugAPI("Unsatble") @MiraiDebugAPI("Unsatble")
object DebugLogger : MiraiLogger by DefaultLogger("Packet Debug").withSwitch() val DebugLogger : MiraiLoggerWithSwitch = DefaultLogger("Packet Debug").withSwitch(false)
@MiraiDebugAPI("Unstable") @MiraiDebugAPI("Unstable")
inline fun Throwable.logStacktrace(message: String? = null) = DebugLogger.error(message, this) inline fun Throwable.logStacktrace(message: String? = null) = DebugLogger.error(message, this)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment