From 0d4f35bed1c95bdd60357619a41fac7c4135b7ba Mon Sep 17 00:00:00 2001 From: Richard van der Hoff Date: Mon, 1 Aug 2016 13:44:04 +0100 Subject: [PATCH] Fix a warning from RoomSubList `selectedRoom` is *not* required, and we often don't have one, so get warnings. --- src/components/structures/RoomSubList.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/components/structures/RoomSubList.js b/src/components/structures/RoomSubList.js index 497acdec..a5a6fd21 100644 --- a/src/components/structures/RoomSubList.js +++ b/src/components/structures/RoomSubList.js @@ -61,8 +61,12 @@ var RoomSubList = React.createClass({ label: React.PropTypes.string.isRequired, tagName: React.PropTypes.string, editable: React.PropTypes.bool, + order: React.PropTypes.string.isRequired, - selectedRoom: React.PropTypes.string.isRequired, + + // undefined if no room is selected (eg we are showing settings) + selectedRoom: React.PropTypes.string, + startAsHidden: React.PropTypes.bool, showSpinner: React.PropTypes.bool, // true to show a spinner if 0 elements when expanded collapsed: React.PropTypes.bool.isRequired, // is LeftPanel collapsed?