diff --git a/src/components/structures/GroupView.js b/src/components/structures/GroupView.js index d1f5de0b95..0be9ffb77a 100644 --- a/src/components/structures/GroupView.js +++ b/src/components/structures/GroupView.js @@ -399,6 +399,9 @@ FeaturedRoom.contextTypes = GroupContext; RoleUserList.contextTypes = GroupContext; FeaturedUser.contextTypes = GroupContext; +const GROUP_JOINABLE = "GROUP_JOINABLE"; +const GROUP_NOT_JOINABLE = "GROUP_NOT_JOINABLE"; + export default React.createClass({ displayName: 'GroupView', @@ -612,7 +615,7 @@ export default React.createClass({ _onJoinableChange: function(ev) { this.setState({ - joinableForm: { isJoinable: ev.target.value === "true" }, + joinableForm: { isJoinable: ev.target.value === GROUP_JOINABLE }, }); }, @@ -949,7 +952,7 @@ export default React.createClass({