From 3f8ddde539604854859c7aa1cbfd50604e21b287 Mon Sep 17 00:00:00 2001 From: Josh Lauer Date: Tue, 8 Aug 2017 08:39:20 -0400 Subject: [PATCH] rely on base Exception class's #message method --- lib/dropbox/errors.rb | 4 ---- 1 file changed, 4 deletions(-) diff --git a/lib/dropbox/errors.rb b/lib/dropbox/errors.rb index 86b207f..46e398f 100644 --- a/lib/dropbox/errors.rb +++ b/lib/dropbox/errors.rb @@ -3,8 +3,6 @@ module Dropbox # Thrown when Dropbox::Client encounters an error unrelated to the API. class ClientError < StandardError - attr_reader :message - def self.invalid_access_token self.new("Invalid access token") end @@ -24,8 +22,6 @@ def to_s # Thrown when the API returns an error response. class ApiError < StandardError - attr_reader :message - def initialize(response) if response.content_type.mime_type == 'application/json' @message = JSON.parse(response)['error_summary']