fix crash in account activity (#1085)
This commit is contained in:
parent
ffcc294107
commit
d5fcbea5ac
1 changed files with 2 additions and 4 deletions
|
@ -463,10 +463,7 @@ class AccountActivity : BottomSheetActivity(), ActionButtonActivity, HasSupportF
|
||||||
|
|
||||||
override fun onCreateOptionsMenu(menu: Menu): Boolean {
|
override fun onCreateOptionsMenu(menu: Menu): Boolean {
|
||||||
menuInflater.inflate(R.menu.account_toolbar, menu)
|
menuInflater.inflate(R.menu.account_toolbar, menu)
|
||||||
return super.onCreateOptionsMenu(menu)
|
|
||||||
}
|
|
||||||
|
|
||||||
override fun onPrepareOptionsMenu(menu: Menu): Boolean {
|
|
||||||
if (!isSelf) {
|
if (!isSelf) {
|
||||||
val follow = menu.findItem(R.id.action_follow)
|
val follow = menu.findItem(R.id.action_follow)
|
||||||
follow.title = if (followState == FollowState.NOT_FOLLOWING) {
|
follow.title = if (followState == FollowState.NOT_FOLLOWING) {
|
||||||
|
@ -510,7 +507,8 @@ class AccountActivity : BottomSheetActivity(), ActionButtonActivity, HasSupportF
|
||||||
menu.removeItem(R.id.action_mute)
|
menu.removeItem(R.id.action_mute)
|
||||||
menu.removeItem(R.id.action_show_reblogs)
|
menu.removeItem(R.id.action_show_reblogs)
|
||||||
}
|
}
|
||||||
return super.onPrepareOptionsMenu(menu)
|
|
||||||
|
return super.onCreateOptionsMenu(menu)
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun showFollowRequestPendingDialog() {
|
private fun showFollowRequestPendingDialog() {
|
||||||
|
|
Loading…
Reference in a new issue