abort_if 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9382641ec11c37ac30b41e19e894327898bd87cb
4
- data.tar.gz: 6b2c23d5e9e3ff6898ec5515c51f7039be43132f
3
+ metadata.gz: 7ff346f835eaf8be62228af05ff85eb2807864b9
4
+ data.tar.gz: 3af9f14d527dd63f7248507be6361f81b50b8adf
5
5
  SHA512:
6
- metadata.gz: da1482e773e97e38268b7d8544f9f5ab60f426ca872e04c93463ea339c282207ab23e46777fa64c4effc9786d3921e3288ed08b70a719f71437e6c2713eda3a4
7
- data.tar.gz: 86e36eb1ea400665994d6ab25cbb2dea44263fd6cb83286034c6e44b03c62123ab439de1a87264f0e6c2dacf7426a487a37d7fdc9b4db99b934924dcfabcb305
6
+ metadata.gz: 7d8ab76f0e2a9d0bb919b04cfc20c9e5f12e4ab45f04acd6500f93bc2af04a038468510cb1bf1b9b353a99ee71d8fba6c40fff8c7c90d36cf4b88cbd8aca8c16
7
+ data.tar.gz: fe49cb8b166cf662997aba7d7a1f466dc7462de7203054cea3d4bc89a95868668de89e74ac4552dc9c48c736a4f9a77f6ccad211ed813c0d0151bfac83ad3d81
@@ -51,10 +51,13 @@ module AbortIf
51
51
  #
52
52
  # @note The abort_if style methods don't interpolate arguments to
53
53
  # msg as the Assert module methods do
54
+ #
55
+ # @note When rescuing AbortIf::Exit, the msg will be passed if you
56
+ # want to display it in the rescue block
54
57
  def abort_if test, msg="Fatal error"
55
58
  if test
56
59
  logger.fatal msg
57
- raise Exit
60
+ raise Exit, msg
58
61
  end
59
62
  end
60
63
 
@@ -17,5 +17,5 @@
17
17
  # along with AbortIf. If not, see <http://www.gnu.org/licenses/>.
18
18
 
19
19
  module AbortIf
20
- VERSION = "0.1.1"
20
+ VERSION = "0.1.2"
21
21
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: abort_if
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Moore