Skip to content

Commit

Permalink
Fix lint issue.
Browse files Browse the repository at this point in the history
  • Loading branch information
Isira-Seneviratne committed Mar 26, 2023
1 parent 00fec11 commit 3bc3f26
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ fun Context.toastFromMainThread(stringId: Int) {
toastFromMainThread(getString(stringId))
}

suspend fun Context.toastFromMainDispatcher(text: String, length: Int = Toast.LENGTH_SHORT) = withContext(
Dispatchers.Main
) {
Toast.makeText(this@toastFromMainDispatcher, text, length).show()
suspend fun Context.toastFromMainDispatcher(text: String, length: Int = Toast.LENGTH_SHORT) {
withContext(Dispatchers.Main) {
Toast.makeText(this@toastFromMainDispatcher, text, length).show()
}
}

suspend fun Context.toastFromMainDispatcher(stringId: Int, length: Int = Toast.LENGTH_SHORT) {
Expand Down

0 comments on commit 3bc3f26

Please sign in to comment.