out of curiosity, which one of these would be pref...
# codereview
r
out of curiosity, which one of these would be preferred?
Copy code
codes.indexOfFirst { it.id == codeId }.let {
        if (it >= 0) {
            notifyItemChanged(it)
        }
    }
Copy code
codes.find { it.id == codeId }?.let { notifyItemChanged(codes.indexOf(it)) }