diff --git a/mastodon/src/main/java/org/joinmastodon/android/fragments/HashtagTimelineFragment.java b/mastodon/src/main/java/org/joinmastodon/android/fragments/HashtagTimelineFragment.java index b5bf46d827..d2a1cc0240 100644 --- a/mastodon/src/main/java/org/joinmastodon/android/fragments/HashtagTimelineFragment.java +++ b/mastodon/src/main/java/org/joinmastodon/android/fragments/HashtagTimelineFragment.java @@ -295,7 +295,7 @@ private void createOptionsMenu(){ followMenuItem=optionsMenu.findItem(R.id.follow_hashtag); pinMenuItem=optionsMenu.findItem(R.id.pin); followMenuItem.setVisible(toolbarContentVisible); - updateFollowState(hashtag.following); + updateFollowState(hashtag!=null && hashtag.following); // pinMenuItem.setShowAsAction(toolbarContentVisible ? MenuItem.SHOW_AS_ACTION_NEVER : MenuItem.SHOW_AS_ACTION_ALWAYS); super.updatePinButton(pinMenuItem);