small fix

This commit is contained in:
Austin Huang 2020-07-31 17:29:03 -04:00
parent ea18758f5a
commit 69a7d67734
No known key found for this signature in database
GPG Key ID: 84C23AA04587A91F
2 changed files with 3 additions and 1 deletions

View File

@ -462,7 +462,7 @@ public final class MainHelper implements SwipeRefreshLayout.OnRefreshListener {
if ((!autoloadPosts || isHashtag) && hasNextPage) {
main.mainBinding.swipeRefreshLayout.setRefreshing(true);
stopCurrentExecutor();
currentlyExecuting = new PostsFetcher(isHashtag ? main.userQuery : main.profileModel.getId(), endCursor, postsFetchListener)
currentlyExecuting = new PostsFetcher((isHashtag || isLocation) ? main.userQuery : main.profileModel.getId(), endCursor, postsFetchListener)
.setUsername(isHashtag ? null : main.profileModel.getUsername())
.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
endCursor = null;

View File

@ -332,6 +332,7 @@ public final class Main extends BaseLanguageActivity {
menu.findItem(R.id.action_settings).setVisible(false);
menu.findItem(R.id.action_dms).setVisible(false);
menu.findItem(R.id.action_quickaccess).setVisible(false);
menu.findItem(R.id.action_notif).setVisible(false);
});
searchAction.setOnActionExpandListener(new MenuItem.OnActionExpandListener() {
@Override
@ -345,6 +346,7 @@ public final class Main extends BaseLanguageActivity {
menu.findItem(R.id.action_settings).setVisible(true);
menu.findItem(R.id.action_dms).setVisible(true);
menu.findItem(R.id.action_quickaccess).setVisible(true);
menu.findItem(R.id.action_notif).setVisible(true);
return true;
}
});