class Berkshelf::BerksfileReadError

def backtrace

def backtrace
  Array(@error_backtrace) + Array(original_backtrace)
end

def initialize(original_error)

Parameters:
  • original_error (#set_status_code) --
def initialize(original_error)
  @original_error  = original_error
  @error_message   = original_error.to_s
  @error_backtrace = original_error.backtrace
end

def status_code

def status_code
  @original_error.respond_to?(:status_code) ? @original_error.status_code : 113
end

def to_s

def to_s
  [
    "An error occurred while reading the Berksfile:",
    "",
    "  #{@error_message}",
  ].join("\n")
end