Created
January 25, 2020 00:11
-
-
Save danielmalone/8b7007bd727417e07b13c0ba55e68382 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
class InvoicesDiff : DiffUtil.ItemCallback<Invoice>() { | |
override fun areItemsTheSame(oldItem: Invoice, newItem: Invoice): Boolean { | |
return oldItem.id == newItem.id | |
} | |
override fun areContentsTheSame(oldItem: Invoice, newItem: Invoice): Boolean { | |
return areItemsTheSame(oldItem, newItem) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment