angels 0.0.7 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. data/lib/angels.rb +11 -1
  2. data/lib/angels/version.rb +1 -1
  3. metadata +2 -2
data/lib/angels.rb CHANGED
@@ -27,7 +27,17 @@ module Angels
27
27
  sleep opts[:loop_sleep]
28
28
  rescue SignalException, Interrupt; SystemExit; Process.exit
29
29
  rescue => e
30
- opts[:exception_handler].try(:call, e)
30
+ handler = opts[:exception_handler]
31
+ if handler
32
+ if handler.is_a? Symbol
33
+ case handler
34
+ when :hoptoad; HoptoadNotifier.notify(e)
35
+ else raise handler.inspect
36
+ end
37
+ else
38
+ handler.call(e)
39
+ end
40
+ end
31
41
  raise e unless opts[:retry]
32
42
  sleep opts[:retry_sleep]
33
43
  end
@@ -1,3 +1,3 @@
1
1
  module Angels
2
- VERSION = "0.0.7"
2
+ VERSION = "0.0.8"
3
3
  end
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 7
9
- version: 0.0.7
8
+ - 8
9
+ version: 0.0.8
10
10
  platform: ruby
11
11
  authors:
12
12
  - Peder Linder