Skip to content
Snippets Groups Projects
Commit 8cf1e426 authored by Janne Mareike Koschinski's avatar Janne Mareike Koschinski
Browse files

Fix lint issues

parent ba70f208
No related branches found
No related tags found
No related merge requests found
Pipeline #3064 failed
......@@ -33,6 +33,7 @@ import android.graphics.Canvas
import android.graphics.drawable.Drawable
import android.net.Uri
import android.os.Build
import androidx.annotation.RequiresApi
import androidx.core.app.ActivityCompat
import androidx.core.app.NotificationCompat
import androidx.core.app.NotificationManagerCompat
......@@ -73,7 +74,7 @@ class QuasseldroidNotificationManager @Inject constructor(private val context: C
prepareChannels()
}
@TargetApi(Build.VERSION_CODES.O)
@RequiresApi(Build.VERSION_CODES.O)
private fun prepareChannels() {
val notificationManager =
context.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager
......
......@@ -113,14 +113,6 @@ class AndroidHandlerThread(name: String) : HandlerThread(name) {
started().let { handler?.postAtFrontOfQueue(r) }
?: throw RuntimeException("Thread not started")
fun removeCallbacks(r: () -> Unit) =
started().let { handler?.removeCallbacks(r) }
?: throw RuntimeException("Thread not started")
fun removeCallbacks(r: () -> Unit, token: Any) =
started().let { handler?.removeCallbacks(r, token) }
?: throw RuntimeException("Thread not started")
fun sendMessage(msg: Message): Boolean =
started().let { handler?.sendMessage(msg) }
?: throw RuntimeException("Thread not started")
......
......@@ -54,4 +54,5 @@
<issue id="NewerVersionAvailable" severity="informational"/>
<issue id="SetTextI18n" severity="informational"/>
<issue id="DefaultLocale" severity="informational"/>
<issue id="UseKtx" severity="informational"/>
</lint>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment