summaryrefslogtreecommitdiffstats
path: root/webapp/actions/webrtc_actions.jsx
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2017-06-26 08:16:57 -0400
committerGitHub <noreply@github.com>2017-06-26 08:16:57 -0400
commit23ccfc845ca2350075f6027e16c6206fc7b71716 (patch)
tree3fd1f896a5a24b43913be03b21c85638dd7c356e /webapp/actions/webrtc_actions.jsx
parentfe7e9d95b30ae2195fcba68db960866db91ce045 (diff)
downloadchat-23ccfc845ca2350075f6027e16c6206fc7b71716.tar.gz
chat-23ccfc845ca2350075f6027e16c6206fc7b71716.tar.bz2
chat-23ccfc845ca2350075f6027e16c6206fc7b71716.zip
Move remaining actions over to use redux and v4 endpoints (#6720)
Diffstat (limited to 'webapp/actions/webrtc_actions.jsx')
-rw-r--r--webapp/actions/webrtc_actions.jsx10
1 files changed, 6 insertions, 4 deletions
diff --git a/webapp/actions/webrtc_actions.jsx b/webapp/actions/webrtc_actions.jsx
index 65820f35c..244de289b 100644
--- a/webapp/actions/webrtc_actions.jsx
+++ b/webapp/actions/webrtc_actions.jsx
@@ -4,7 +4,7 @@
import AppDispatcher from 'dispatcher/app_dispatcher.jsx';
import {WebrtcActionTypes} from 'utils/constants.jsx';
-import Client from 'client/web_client.jsx';
+import {Client4} from 'mattermost-redux/client';
export function initWebrtc(userId, isCalling) {
AppDispatcher.handleServerAction({
@@ -22,15 +22,17 @@ export function handle(message) {
}
export function webrtcToken(success, error) {
- Client.webrtcToken(
+ Client4.webrtcToken().then(
(data) => {
if (success) {
success(data);
}
- },
+ }
+ ).catch(
() => {
if (error) {
error();
}
- });
+ }
+ );
}