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

Commit

Permalink
adjust if statement and update comment as per pr feedback
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
  • Loading branch information
t3chguy committed Jun 19, 2018
1 parent 2f15231 commit 2fd5833
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/structures/RoomSubList.js
Original file line number Diff line number Diff line change
Expand Up @@ -335,9 +335,9 @@ const RoomSubList = React.createClass({
const TruncatedList = sdk.getComponent('elements.TruncatedList');

let content;
if (this.state.sortedList.length === 0) {
// check if emptyContent is defined, if falsey then don't show an empty sublist even without searchFilter
if (!this.props.searchFilter && this.props.extraTiles.length === 0 && this.props.emptyContent) {
if (this.state.sortedList.length === 0 && this.props.extraTiles.length === 0) {
// if no search filter is applied and there is a placeholder defined then show it, otherwise show nothing
if (!this.props.searchFilter && this.props.emptyContent) {
content = this.props.emptyContent;
} else {
// don't show an empty sublist
Expand Down

0 comments on commit 2fd5833

Please sign in to comment.