Skip to content
This repository has been archived by the owner on Jun 1, 2024. It is now read-only.

NullPointerException on specific post #3471

Open
the-blank-x opened this issue Sep 10, 2022 · 0 comments
Open

NullPointerException on specific post #3471

the-blank-x opened this issue Sep 10, 2022 · 0 comments

Comments

@the-blank-x
Copy link

Slide version: 6.7.1
Android version: 9

Opening https://redd.it/xa1csr crashes Slide, Logcat shows:

FATAL EXCEPTION: main
Process: me.ccrama.redditslide, PID: 22512
java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.startsWith(java.lang.String)' on a null object reference
	at me.ccrama.redditslide.ContentType.getContentType(ContentType.java:137)
	at me.ccrama.redditslide.ContentType.getContentType(ContentType.java:239)
	at me.ccrama.redditslide.SubmissionViews.PopulateSubmissionViewHolder.populateSubmissionViewHolder(PopulateSubmissionViewHolder.java:2643)
	at me.ccrama.redditslide.Adapters.CommentAdapter.onBindViewHolder(CommentAdapter.java:555)
	at androidx.recyclerview.widget.RecyclerView$Adapter.onBindViewHolder(RecyclerView.java:7254)
	at androidx.recyclerview.widget.RecyclerView$Adapter.bindViewHolder(RecyclerView.java:7337)
	at androidx.recyclerview.widget.RecyclerView$Recycler.tryBindViewHolderByDeadline(RecyclerView.java:6194)
	at androidx.recyclerview.widget.RecyclerView$Recycler.tryGetViewHolderForPositionByDeadline(RecyclerView.java:6460)
	at androidx.recyclerview.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:6300)
	at androidx.recyclerview.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:6296)
	at androidx.recyclerview.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:2330)
	at androidx.recyclerview.widget.LinearLayoutManager.layoutChunk(LinearLayoutManager.java:1631)
	at androidx.recyclerview.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1591)
	at androidx.recyclerview.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:668)
	at me.ccrama.redditslide.Views.PreCachingLayoutManagerComments.onLayoutChildren(PreCachingLayoutManagerComments.java:20)
	at androidx.recyclerview.widget.RecyclerView.dispatchLayoutStep2(RecyclerView.java:4309)
	at androidx.recyclerview.widget.RecyclerView.dispatchLayout(RecyclerView.java:4012)
	at androidx.recyclerview.widget.RecyclerView.onLayout(RecyclerView.java:4578)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at androidx.swiperefreshlayout.widget.SwipeRefreshLayout.onLayout(SwipeRefreshLayout.java:625)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323)
	at android.widget.FrameLayout.onLayout(FrameLayout.java:261)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at androidx.viewpager.widget.ViewPager.onLayout(ViewPager.java:1775)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at androidx.coordinatorlayout.widget.CoordinatorLayout.layoutChild(CoordinatorLayout.java:1213)
	at androidx.coordinatorlayout.widget.CoordinatorLayout.onLayoutChild(CoordinatorLayout.java:899)
	at androidx.coordinatorlayout.widget.CoordinatorLayout.onLayout(CoordinatorLayout.java:919)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323)
	at android.widget.FrameLayout.onLayout(FrameLayout.java:261)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1812)
	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1656)
	at android.widget.LinearLayout.onLayout(LinearLayout.java:1565)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323)
	at android.widget.FrameLayout.onLayout(FrameLayout.java:261)
	at android.view.View.layout(View.java:20831)
	at android.view.ViewGroup.layout(ViewGroup.java:6203)
	at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1812)
	at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1656)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant