Last active
February 22, 2023 18:51
-
-
Save ademirqueiroga/0b370d77fcaf5d982c3bf299cc8009ea to your computer and use it in GitHub Desktop.
Insert/Update channel
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
when (existingChannel) { | |
null -> context.contentResolver.insert( | |
TvContractCompat.Channels.CONTENT_URI, | |
channel.toContentValues() | |
) | |
else -> context.contentResolver.update( | |
TvContractCompat.Channels.CONTENT_URI, | |
channel.toContentValues(), | |
null, | |
null | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment