summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2017-04-24 23:41:36 -0300
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2017-04-24 23:41:36 -0300
commitdd1157c80b90728a71b1f3a723e2cdeb335ab1b3 (patch)
treec2d32155c40b88de78c08bbd27e544527a7e4cb4
parent30794972f46de4d3af1c3f1843d46f1162660c3e (diff)
downloadgitlab-ce-dd1157c80b90728a71b1f3a723e2cdeb335ab1b3.tar.gz
Use Class.new(SuperClass) to define an empty custom error class
-rw-r--r--lib/github/error.rb6
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