diff --git a/app/build.gradle b/app/build.gradle index b3b70cec..8a1f1277 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -36,7 +36,7 @@ android { } dependencies { - implementation 'com.simplemobiletools:commons:5.25.1' + implementation 'com.simplemobiletools:commons:5.25.2' implementation 'androidx.constraintlayout:constraintlayout:2.0.0-beta4' implementation 'org.greenrobot:eventbus:3.2.0' } diff --git a/app/src/main/kotlin/com/simplemobiletools/smsmessenger/extensions/Context.kt b/app/src/main/kotlin/com/simplemobiletools/smsmessenger/extensions/Context.kt index cddae58b..b99bd52e 100644 --- a/app/src/main/kotlin/com/simplemobiletools/smsmessenger/extensions/Context.kt +++ b/app/src/main/kotlin/com/simplemobiletools/smsmessenger/extensions/Context.kt @@ -474,5 +474,6 @@ fun Context.getThreadId(address: String): Long { fun Context.isNumberBlocked(number: String): Boolean { val blockedNumbers = getBlockedNumbers() - return blockedNumbers.map { it.number }.contains(number) && !blockedNumbers.map { it.normalizedNumber }.contains(number) + val numberToCompare = number.trimToComparableNumber() + return blockedNumbers.map { it.numberToCompare }.contains(numberToCompare) }