Last active
November 7, 2017 06:42
-
-
Save Shahgupta4sq/e584b0f169db1d260656e405b75d7d6f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private val status = SingleLiveEvent<Status>() | |
fun getStatus(): LiveData<Status> { | |
return status | |
} | |
fun handleImage(intent: Intent?) { | |
intent?.data?.let { | |
avatar.value = it.toString() | |
} ?: run { status.value = Status.INVALID_URI } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment