Exception: StandardError

Inherits:
Exception
  • Object
show all
Defined in:
lib/peep-show/exceptions/standard_error.rb

Instance Method Summary collapse

Instance Method Details

#to_s(*args) ⇒ Object



3
4
5
6
7
8
9
10
11
# File 'lib/peep-show/exceptions/standard_error.rb', line 3

def to_s(*args)
  peeps_exception = "#{PeepShow::Exceptions::Base.phrase}"

  # Don't print an empty message
  if(!super.empty? && super != self.class.to_s)
    peeps_exception << "\n#{super}"
  end
  peeps_exception
end