lib/whois/parser.rb in whois-parser-1.0.1 vs lib/whois/parser.rb in whois-parser-1.1.0
- old
+ new
@@ -1,11 +1,11 @@
#--
# Ruby Whois
#
# An intelligent pure Ruby WHOIS client and parser.
#
-# Copyright (c) 2009-2015 Simone Carletti <weppos@weppos.net>
+# Copyright (c) 2009-2018 Simone Carletti <weppos@weppos.net>
#++
require 'whois'
require 'active_support/core_ext/array/extract_options'
@@ -51,9 +51,24 @@
# * {Whois::Parser::METHODS}
# * {Whois::Parser::PROPERTIES}
#
module Whois
class Parser
+
+ # Appends `Please report issue to` to the message
+ # and raises a new +error+ with the final message.
+ #
+ # @param [Exception] error
+ # @param [String] message
+ # @return [void]
+ #
+ # @api private
+ # @private
+ def bug!(error, message)
+ raise error, message.dup +
+ " Please report the issue at" +
+ " http://github.com/weppos/whois-parser/issues"
+ end
METHODS = [
:contacts,
:changed?, :unchanged?,
# :response_incomplete?, :response_throttled?, :response_unavailable?,