From 2b5ec4a3c076bb1f18eeafbd96b0a80c6b8bfbaa Mon Sep 17 00:00:00 2001
From: JoramWilander <jwawilander@gmail.com>
Date: Thu, 15 Oct 2015 10:44:04 -0400
Subject: Small refactor of websocket code on client and server

---
 web/react/utils/constants.jsx | 12 ++++++++++++
 1 file changed, 12 insertions(+)

(limited to 'web/react/utils/constants.jsx')

diff --git a/web/react/utils/constants.jsx b/web/react/utils/constants.jsx
index b7b8d3c60..b2e9bc6a7 100644
--- a/web/react/utils/constants.jsx
+++ b/web/react/utils/constants.jsx
@@ -47,6 +47,18 @@ module.exports = {
         SERVER_ACTION: null,
         VIEW_ACTION: null
     }),
+
+    SocketEvents: {
+        POSTED: 'posted',
+        POST_EDITED: 'post_edited',
+        POST_DELETED: 'post_deleted',
+        CHANNEL_VIEWED: 'channel_viewed',
+        NEW_USER: 'new_user',
+        USER_ADDED: 'user_added',
+        USER_REMOVED: 'user_removed',
+        TYPING: 'user_typing'
+    },
+
     SPECIAL_MENTIONS: ['all', 'channel'],
     CHARACTER_LIMIT: 4000,
     IMAGE_TYPES: ['jpg', 'gif', 'bmp', 'png', 'jpeg'],
-- 
cgit v1.2.3-1-g7c22


From 20723437aa607abdfa0e9353927e8bf8694a6b2c Mon Sep 17 00:00:00 2001
From: JoramWilander <jwawilander@gmail.com>
Date: Thu, 15 Oct 2015 10:57:09 -0400
Subject: Fix typing socket constant

---
 web/react/utils/constants.jsx | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'web/react/utils/constants.jsx')

diff --git a/web/react/utils/constants.jsx b/web/react/utils/constants.jsx
index b2e9bc6a7..5eb8378ca 100644
--- a/web/react/utils/constants.jsx
+++ b/web/react/utils/constants.jsx
@@ -56,7 +56,7 @@ module.exports = {
         NEW_USER: 'new_user',
         USER_ADDED: 'user_added',
         USER_REMOVED: 'user_removed',
-        TYPING: 'user_typing'
+        TYPING: 'typing'
     },
 
     SPECIAL_MENTIONS: ['all', 'channel'],
-- 
cgit v1.2.3-1-g7c22

