fix: headerAdaptor crash
This commit is contained in:
parent
18778f3c5a
commit
acef7c3d5e
1 changed files with 3 additions and 1 deletions
|
@ -199,7 +199,9 @@ class SearchActivity : AppCompatActivity() {
|
||||||
|
|
||||||
var state: Parcelable? = null
|
var state: Parcelable? = null
|
||||||
override fun onPause() {
|
override fun onPause() {
|
||||||
headerAdaptor.addHistory()
|
if (this::headerAdaptor.isInitialized) {
|
||||||
|
headerAdaptor.addHistory()
|
||||||
|
}
|
||||||
super.onPause()
|
super.onPause()
|
||||||
state = binding.searchRecyclerView.layoutManager?.onSaveInstanceState()
|
state = binding.searchRecyclerView.layoutManager?.onSaveInstanceState()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue