Better logic for checking if channel has loaded
Этот коммит содержится в:
@@ -135,6 +135,8 @@ func createUser(c *Context, w http.ResponseWriter, r *http.Request) {
|
|||||||
user.EmailVerified = true
|
user.EmailVerified = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
user.EmailVerified = true
|
||||||
|
|
||||||
ruser := CreateUser(c, team, user)
|
ruser := CreateUser(c, team, user)
|
||||||
if c.Err != nil {
|
if c.Err != nil {
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -79,7 +79,7 @@ module.exports = React.createClass({
|
|||||||
<button data-toggle="modal" data-target="#new_channel" data-channeltype={this.state.channel_type} type="button" className="btn btn-primary channel-create-btn" onClick={this.handleNewChannel}>Create New Channel</button>
|
<button data-toggle="modal" data-target="#new_channel" data-channeltype={this.state.channel_type} type="button" className="btn btn-primary channel-create-btn" onClick={this.handleNewChannel}>Create New Channel</button>
|
||||||
</div>
|
</div>
|
||||||
<div className="modal-body">
|
<div className="modal-body">
|
||||||
{moreChannels ?
|
{!moreChannels.loading ?
|
||||||
(moreChannels.length ?
|
(moreChannels.length ?
|
||||||
<table className="more-channel-table table">
|
<table className="more-channel-table table">
|
||||||
<tbody>
|
<tbody>
|
||||||
|
|||||||
@@ -202,13 +202,18 @@ var ChannelStore = assign({}, EventEmitter.prototype, {
|
|||||||
BrowserStore.setItem("more_channels", JSON.stringify(channels));
|
BrowserStore.setItem("more_channels", JSON.stringify(channels));
|
||||||
},
|
},
|
||||||
_getMoreChannels: function() {
|
_getMoreChannels: function() {
|
||||||
var channels;
|
var channels = null;
|
||||||
try {
|
try {
|
||||||
channels = JSON.parse(BrowserStore.getItem("more_channels"));
|
channels = JSON.parse(BrowserStore.getItem("more_channels"));
|
||||||
}
|
}
|
||||||
catch (err) {
|
catch (err) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (channels == null) {
|
||||||
|
channels = {};
|
||||||
|
channels.loading = true;
|
||||||
|
}
|
||||||
|
|
||||||
return channels;
|
return channels;
|
||||||
},
|
},
|
||||||
_storeExtraInfos: function(extraInfos) {
|
_storeExtraInfos: function(extraInfos) {
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user