diff --git a/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/AbsStatusesFragment.kt b/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/AbsStatusesFragment.kt index 902146e34..b6b73abe9 100644 --- a/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/AbsStatusesFragment.kt +++ b/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/AbsStatusesFragment.kt @@ -47,9 +47,12 @@ import org.mariotaku.twidere.adapter.decorator.DividerItemDecoration import org.mariotaku.twidere.adapter.iface.ILoadMoreSupportAdapter import org.mariotaku.twidere.annotation.ReadPositionTag import org.mariotaku.twidere.annotation.Referral -import org.mariotaku.twidere.constant.* import org.mariotaku.twidere.constant.IntentConstants.* import org.mariotaku.twidere.constant.KeyboardShortcutConstants.* +import org.mariotaku.twidere.constant.displaySensitiveContentsKey +import org.mariotaku.twidere.constant.newDocumentApiKey +import org.mariotaku.twidere.constant.readFromBottomKey +import org.mariotaku.twidere.constant.rememberPositionKey import org.mariotaku.twidere.extension.model.getAccountType import org.mariotaku.twidere.graphic.like.LikeAnimationDrawable import org.mariotaku.twidere.loader.iface.IExtendedLoader @@ -403,7 +406,8 @@ abstract class AbsStatusesFragment protected constructor() : override fun onQuotedStatusClick(holder: IStatusViewHolder, position: Int) { val status = adapter.getStatus(position) ?: return - IntentUtils.openStatus(activity, status.account_key, status.quoted_id) + val quotedId = status.quoted_id ?: return + IntentUtils.openStatus(activity, status.account_key, quotedId) } override fun onStatusLongClick(holder: IStatusViewHolder, position: Int): Boolean { diff --git a/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/StatusFragment.kt b/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/StatusFragment.kt index 8a9978c32..c181c46fc 100644 --- a/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/StatusFragment.kt +++ b/twidere/src/main/kotlin/org/mariotaku/twidere/fragment/StatusFragment.kt @@ -1080,7 +1080,8 @@ class StatusFragment : BaseFragment(), LoaderCallbacks { - IntentUtils.openStatus(adapter.context, status.account_key, status.quoted_id) + val quotedId = status.quoted_id ?: return + IntentUtils.openStatus(adapter.context, status.account_key, quotedId) } itemView.translateLabel -> { fragment.loadTranslation(adapter.status)