Skip to content

Commit

Permalink
NTV-48: Migrate DiscoveryViewModel.java to kotlin (#1378)
Browse files Browse the repository at this point in the history
* Convert discovery view model to kotlin and update tests

* Linter

* Linter

* Remove typo causing compile time error
  • Loading branch information
leighdouglas committed Aug 30, 2021
1 parent 86532f3 commit 4058182
Show file tree
Hide file tree
Showing 6 changed files with 617 additions and 706 deletions.
2 changes: 1 addition & 1 deletion app/src/main/java/com/kickstarter/libs/BuildCheck.java
Expand Up @@ -15,5 +15,5 @@ public interface BuildCheck {
.filter(InternalBuildEnvelope::newerBuildAvailable)
.compose(viewModel.bindToLifecycle())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(viewModel.inputs::newerBuildIsAvailable, e -> Timber.e(e.toString()));
.subscribe(viewModel.getInputs()::newerBuildIsAvailable, e -> Timber.e(e.toString()));
}
Expand Up @@ -201,7 +201,7 @@ class DiscoveryActivity : BaseActivity<DiscoveryViewModel.ViewModel>() {
viewModel.outputs.showErrorMessage()
.compose(bindToLifecycle())
.compose(Transformers.observeForUI())
.subscribe { this@DiscoveryActivity.showErrorSnackBar(binding.discoveryAnchorView, it) }
.subscribe { this@DiscoveryActivity.showErrorSnackBar(binding.discoveryAnchorView, it ?: "") }

binding.qualtricsPromptLayout.qualtricsConfirm.setOnClickListener {
qualtricsConfirmClicked()
Expand Down

0 comments on commit 4058182

Please sign in to comment.