add brackets and white spaces to follow code style
This commit is contained in:
parent
bb12ca5e87
commit
7b1b34dbbe
|
@ -454,11 +454,18 @@ fun Context.getNameAndPhotoFromPhoneNumber(number: String): NamePhoto? {
|
||||||
|
|
||||||
fun Context.updateUnreadCountBadge(conversations : ArrayList<Conversation>){
|
fun Context.updateUnreadCountBadge(conversations : ArrayList<Conversation>){
|
||||||
var count = 0
|
var count = 0
|
||||||
|
|
||||||
conversations.forEach {
|
conversations.forEach {
|
||||||
if(!it.read) count++
|
if(!it.read) {
|
||||||
|
count++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(count == 0) {
|
||||||
|
ShortcutBadger.removeCount(this)
|
||||||
|
} else {
|
||||||
|
ShortcutBadger.applyCount(this,count)
|
||||||
}
|
}
|
||||||
if(count == 0) ShortcutBadger.removeCount(this)
|
|
||||||
else ShortcutBadger.applyCount(this,count)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue