diff options
author | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2017-04-24 23:41:36 -0300 |
---|---|---|
committer | Douglas Barbosa Alexandre <dbalexandre@gmail.com> | 2017-04-24 23:41:36 -0300 |
commit | dd1157c80b90728a71b1f3a723e2cdeb335ab1b3 (patch) | |
tree | c2d32155c40b88de78c08bbd27e544527a7e4cb4 /lib | |
parent | 30794972f46de4d3af1c3f1843d46f1162660c3e (diff) | |
download | gitlab-ce-dd1157c80b90728a71b1f3a723e2cdeb335ab1b3.tar.gz |
Use Class.new(SuperClass) to define an empty custom error class
Diffstat (limited to 'lib')
-rw-r--r-- | lib/github/error.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/github/error.rb b/lib/github/error.rb index 41cd4c67847..dfca3a18f9c 100644 --- a/lib/github/error.rb +++ b/lib/github/error.rb @@ -1,6 +1,4 @@ module Github - class Error < StandardError - end - - class RepositoryFetchError < Error; end + Error = Class.new(StandardError) + RepositoryFetchError = Class.new(Github::Error) end |