diff options
author | Christopher Speller <crspeller@gmail.com> | 2016-03-01 08:27:57 -0500 |
---|---|---|
committer | Christopher Speller <crspeller@gmail.com> | 2016-03-01 08:27:57 -0500 |
commit | a66e9513ad48089f16469509ab4fad633f8eaac5 (patch) | |
tree | 8ec3b1be136733b7be7f6aeee2e91b81cebf245c /web/react/components/channel_loader.jsx | |
parent | 39c83f70fc227e9bb88c24b15ff2b8748e9d670b (diff) | |
parent | 6c18e13f8ae4d8785b598adc0cb3e93c27cec849 (diff) | |
download | chat-a66e9513ad48089f16469509ab4fad633f8eaac5.tar.gz chat-a66e9513ad48089f16469509ab4fad633f8eaac5.tar.bz2 chat-a66e9513ad48089f16469509ab4fad633f8eaac5.zip |
Merge pull request #2276 from mattermost/PLT-2030
PLT-2030 fixing error handling
Diffstat (limited to 'web/react/components/channel_loader.jsx')
-rw-r--r-- | web/react/components/channel_loader.jsx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/web/react/components/channel_loader.jsx b/web/react/components/channel_loader.jsx index f3000ee05..e47f2aa50 100644 --- a/web/react/components/channel_loader.jsx +++ b/web/react/components/channel_loader.jsx @@ -6,6 +6,7 @@ AsyncClient with requests. */ import * as AsyncClient from '../utils/async_client.jsx'; +import * as Client from '../utils/client.jsx'; import SocketStore from '../stores/socket_store.jsx'; import ChannelStore from '../stores/channel_store.jsx'; import PostStore from '../stores/post_store.jsx'; @@ -45,6 +46,14 @@ const holders = defineMessages({ wrote: { id: 'channel_loader.wrote', defaultMessage: ' wrote: ' + }, + connectionError: { + id: 'channel_loader.connection_error', + defaultMessage: 'There appears to be a problem with your internet connection.' + }, + unknownError: { + id: 'channel_loader.unknown_error', + defaultMessage: 'We received an unexpected status code from the server.' } }); @@ -67,6 +76,11 @@ class ChannelLoader extends React.Component { wrote: formatMessage(holders.wrote) }); + Client.setTranslations({ + connectionError: formatMessage(holders.connectionError), + unknownError: formatMessage(holders.unknownError) + }); + this.state = {}; } componentDidMount() { |