fix crash when AccountMediaFragment was recreated
This commit is contained in:
parent
59bcb6f0bf
commit
f35ff105e9
|
@ -120,10 +120,9 @@ class AccountMediaFragment : BaseFragment() {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onAttach(context: Context) {
|
override fun onActivityCreated(savedInstanceState: Bundle?) {
|
||||||
super.onAttach(context)
|
super.onActivityCreated(savedInstanceState)
|
||||||
// we should get rid of this
|
api = (activity as BaseActivity).mastodonApi
|
||||||
api = (context as BaseActivity).mastodonApi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?,
|
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?,
|
||||||
|
|
Loading…
Reference in New Issue