adding a null check at closing search

This commit is contained in:
tibbi 2018-01-08 13:25:01 +01:00
parent 78148990f0
commit 0fa4cb5844
1 changed files with 3 additions and 1 deletions

View File

@ -137,7 +137,9 @@ class MediaActivity : SimpleActivity(), MediaAdapter.MediaOperationsListener {
override fun onStop() {
super.onStop()
MenuItemCompat.collapseActionView(mSearchMenuItem)
if (mSearchMenuItem != null) {
MenuItemCompat.collapseActionView(mSearchMenuItem)
}
}
override fun onDestroy() {