You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-08 21:42:24 +03:00
Make UserSettings use the right teamToken
This threads the correct teamToken through to UserSettings for generating the referral section.
This commit is contained in:
@@ -109,6 +109,10 @@ module.exports = React.createClass({
|
||||
|
||||
// true if RightPanel is collapsed
|
||||
collapsedRhs: React.PropTypes.bool,
|
||||
|
||||
// Team token for the referral link. If falsy, the referral section will
|
||||
// not appear
|
||||
teamToken: React.PropTypes.string,
|
||||
},
|
||||
|
||||
getDefaultProps: function() {
|
||||
@@ -462,7 +466,7 @@ module.exports = React.createClass({
|
||||
},
|
||||
|
||||
_renderReferral: function() {
|
||||
const teamToken = window.localStorage.getItem('mx_team_token');
|
||||
const teamToken = this.props.teamToken;
|
||||
if (!teamToken) {
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user