fix to load conversation list (restricted user status)

when the user status app on server is restricted to only some groups, the capabilities for users that are excluded still contains the "user_status" capability.
For the android talk app, this caused that the conversations were not shown.
With this fix, the conversations will be loaded also if the "user_status" is mistakenly set. Additionally, the option to set the status will be hidden.

Signed-off-by: Marcel Hibbe <dev@mhibbe.de>
This commit is contained in:
Marcel Hibbe 2022-06-10 15:02:58 +02:00 committed by Marcel Hibbe (Rebase PR Action)
parent bb99161e63
commit c628c23557
2 changed files with 2 additions and 1 deletions

View File

@ -543,13 +543,13 @@ public class ConversationsListController extends BaseController implements Flexi
@Override @Override
public void onError(@io.reactivex.annotations.NonNull Throwable e) { public void onError(@io.reactivex.annotations.NonNull Throwable e) {
Log.e(TAG, "failed to fetch user statuses", e); Log.e(TAG, "failed to fetch user statuses", e);
fetchRooms();
} }
@Override @Override
public void onComplete() { public void onComplete() {
} }
}); });
} }
private void fetchRooms() { private void fetchRooms() {

View File

@ -233,6 +233,7 @@ public class ChooseAccountDialogFragment extends DialogFragment {
@Override @Override
public void onError(@NonNull Throwable e) { public void onError(@NonNull Throwable e) {
Log.e(TAG, "Can't receive user status from server. ", e); Log.e(TAG, "Can't receive user status from server. ", e);
binding.statusView.setVisibility(View.GONE);
} }
@Override @Override