Skip to content

Commit

Permalink
Move the loading displaying in Login, on the UI thread
Browse files Browse the repository at this point in the history
  • Loading branch information
florina-muntenescu committed Nov 2, 2018
1 parent 1ebd3b7 commit 83c6a10
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ buildscript {
}

dependencies {
classpath 'com.android.tools.build:gradle:3.3.0-beta01'
classpath 'com.android.tools.build:gradle:3.3.0-beta02'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:${versions.kotlin}"
classpath "com.google.gms:google-services:${versions.googleServices}"
classpath "io.fabric.tools:gradle:${versions.fabric}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ class LoginViewModel @Inject constructor(
if (!isLoginValid(username, password)) {
return@launch
}
showLoading()
withContext(dispatcherProvider.main) { showLoading() }
val result = loginRepository.login(username, password)

withContext(dispatcherProvider.main) {
Expand Down

0 comments on commit 83c6a10

Please sign in to comment.