Skip to content

Instantly share code, notes, and snippets.

@jeremyrempel
Created February 18, 2019 17:17
Show Gist options
  • Save jeremyrempel/dbddd0ac12594193ec52c7036b089d6b to your computer and use it in GitHub Desktop.
Save jeremyrempel/dbddd0ac12594193ec52c7036b089d6b to your computer and use it in GitHub Desktop.
import android.util.Log
actual fun log(level: LogLevel, tag: String, message: String, error: Throwable) {
when (level) {
is LogLevel.DEBUG -> Log.d(tag, message, error)
is LogLevel.INFO -> Log.i(tag, message, error)
is LogLevel.WARN -> Log.w(tag, message, error)
is LogLevel.ERROR -> Log.e(tag, message, error)
}
}
@lehanphong
Copy link

how import "import android.util.Log" in ShareCode module? I can't :'(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment