Fix crash when recent manga has no title

This commit is contained in:
Jays2Kings 2021-04-23 14:55:13 -04:00
parent 87ef22003c
commit 704f57300b

View File

@ -68,8 +68,8 @@ class MangaShortcutManager(
context,
"Manga-${item.id?.toString() ?: item.title}"
)
.setShortLabel(item.title)
.setLongLabel(item.title)
.setShortLabel(item.title.takeUnless { it.isNotBlank() } ?: context.getString(R.string.manga))
.setLongLabel(item.title.takeUnless { it.isNotBlank() } ?: context.getString(R.string.manga))
.setIcon(
if (bitmap != null) if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {
Icon.createWithAdaptiveBitmap(bitmap.toSquare())