summaryrefslogtreecommitdiff
path: root/deployment_scripts/puppet/files/embedded/lib/ruby/gems/2.3.0/gems/cause-0.1/lib/cause.rb
blob: 0c3394c909cbb01ac6cc4990aaacdc9dd8cb204a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
class Exception
  unless method_defined?(:cause)
    attr_reader :cause

    alias old_initialize initialize

    def initialize(*a)
      @cause = $!
      old_initialize(*a)
    end
  end
end