diff options
Diffstat (limited to 'web/react/utils/utils.jsx')
-rw-r--r-- | web/react/utils/utils.jsx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/web/react/utils/utils.jsx b/web/react/utils/utils.jsx index 618cc1557..f0a343513 100644 --- a/web/react/utils/utils.jsx +++ b/web/react/utils/utils.jsx @@ -982,3 +982,12 @@ module.exports.getUserIdFromChannelName = function(channel) { return otherUserId; }; + +module.exports.importSlack = function(file, success, error) { + formData = new FormData(); + formData.append('file', file, file.name); + formData.append('filesize', file.size); + formData.append('importFrom', 'slack'); + + client.importSlack(formData, success, error); +}; |