Skip to content

Instantly share code, notes, and snippets.

@TorkelV
Last active October 20, 2020 22:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save TorkelV/fb581317ec3cb4e678df114880ca7707 to your computer and use it in GitHub Desktop.
Save TorkelV/fb581317ec3cb4e678df114880ca7707 to your computer and use it in GitHub Desktop.
val canAddNewPhrase: LiveData<Boolean> = Lives.combineLatest(phrase, translation){
phrase, translation -> phrase.isNotEmpty() && translation.isNotEmpty()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment