Move instances of Client.updateChannelPurpose() in components to an action (#5096)
Этот коммит содержится в:
коммит произвёл
Joram Wilander
родитель
24553164b6
Коммит
61b7226533
@@ -364,6 +364,25 @@ export function createChannel(channel, success, error) {
|
||||
);
|
||||
}
|
||||
|
||||
export function updateChannelPurpose(channelId, purposeValue, success, error) {
|
||||
Client.updateChannelPurpose(
|
||||
channelId,
|
||||
purposeValue,
|
||||
() => {
|
||||
AsyncClient.getChannel(channelId);
|
||||
|
||||
if (success) {
|
||||
success();
|
||||
}
|
||||
},
|
||||
(err) => {
|
||||
if (error) {
|
||||
error(err);
|
||||
}
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
export function updateChannelHeader(channelId, header, success, error) {
|
||||
Client.updateChannelHeader(
|
||||
channelId,
|
||||
|
||||
Ссылка в новой задаче
Block a user