#1304 - Create blocking client for built-in android blocking

This commit is contained in:
moezbhatti
2019-06-20 01:27:15 -04:00
parent 60f41d9996
commit afa6199897
9 changed files with 125 additions and 12 deletions
@@ -57,7 +57,7 @@ class ReceiveMms @Inject constructor(
// to check if it should be blocked after we've pulled it into realm. If it
// turns out that it should be dropped, then delete it
// TODO Don't store blocked messages in the first place
val shouldBlock = blockingClient.shouldBlock(message.address).blockingGet()
val shouldBlock = blockingClient.isBlocked(message.address).blockingGet()
val shouldDrop = prefs.drop.get()
Timber.v("block=$shouldBlock, drop=$shouldDrop")
@@ -49,7 +49,7 @@ class ReceiveSms @Inject constructor(
// Don't continue if the sender is blocked
val messages = it.messages
val address = messages[0].displayOriginatingAddress
val shouldBlock = blockingClient.shouldBlock(address).blockingGet()
val shouldBlock = blockingClient.isBlocked(address).blockingGet()
val shouldDrop = prefs.drop.get()
Timber.v("block=$shouldBlock, drop=$shouldDrop")