diff options
Diffstat (limited to 'lib/mattermost/client.rb')
-rw-r--r-- | lib/mattermost/client.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/mattermost/client.rb b/lib/mattermost/client.rb index fa3c9fa27bd..ec2903b7ec6 100644 --- a/lib/mattermost/client.rb +++ b/lib/mattermost/client.rb @@ -30,12 +30,12 @@ module Mattermost json_response = JSON.parse(response.body) unless response.success? - raise ClientError(json_response['message'] || 'Undefined error') + raise Mattermost::ClientError.new(json_response['message'] || 'Undefined error') end json_response rescue JSON::JSONError - raise ClientError('Cannot parse response') + raise Mattermost::ClientError.new('Cannot parse response') end end end |