Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Fix checks to show prompt to start new chats #6812

Merged
merged 2 commits into from
Sep 15, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Fix checks to show prompt to start new chats
We compared the length of the list rooms but not historical or favourite.

Caught by new version of typescript when I tried to upgrade.
  • Loading branch information
dbkr committed Sep 15, 2021
commit 0f98c9127d5cb2c6d6349c42dc05b2877f506fb3
2 changes: 1 addition & 1 deletion src/components/views/rooms/RoomList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ export default class RoomList extends React.PureComponent<IProps, IState> {
const unfilteredHistorical = unfilteredLists[DefaultTagID.Archived] || [];
const unfilteredFavourite = unfilteredLists[DefaultTagID.Favourite] || [];
// show a prompt to join/create rooms if the user is in 0 rooms and no historical
if (unfilteredRooms.length < 1 && unfilteredHistorical < 1 && unfilteredFavourite < 1) {
if (unfilteredRooms.length < 1 && unfilteredHistorical.length < 1 && unfilteredFavourite.length < 1) {
explorePrompt = <div className="mx_RoomList_explorePrompt">
<div>{ _t("Use the + to make a new room or explore existing ones below") }</div>
<AccessibleButton
Expand Down