ronad 0.4.0 → 0.5.0

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: aa2e90a31f98cc6989741b478cc1d3da81578c10
4
- data.tar.gz: 261e18b674b19d0e8521dc9272111ea963648b9e
3
+ metadata.gz: a82e00f9bcba4e7a6155341249da26a213fdd501
4
+ data.tar.gz: ae3e3f1e170d23ce89367f91a2a957505e6d535b
5
5
  SHA512:
6
- metadata.gz: bec8a6010fa768e26dad85aac978d262e83d519509be3934635459a73d644ab42bec7dff49094839855a2771bdc8f4fbb51b7cb267b8b696a8399165deb5f038
7
- data.tar.gz: 35d94b5b3967ac127a7c21e020b16ef4ebd72193222feb68f6c1e8b34b1d759dc537e7e5a8c506cbb72cfd6d8a1d40c74b6f671e74f2db75c4be5bfa608d525b
6
+ metadata.gz: 7c53689b785b9adc4e2912f57bf68d2726ba5329f70e6205b9fa0da17084afffe6ea8754f03406cc5a38b843dec3f0a3038f6f7a598eb7a8bf02973e4e6ac66d
7
+ data.tar.gz: 79cdef00ad7d7ab92b1fe2f9ce2d406cc5c04c3ddbf29ab1ee5325183783e8e27e7e58bda295c0974723210ec37408b6f2a153e3a7175ead8275e4671fbb2692
data/lib/ronad/maybe.rb CHANGED
@@ -53,5 +53,14 @@ module Ronad
53
53
  end
54
54
  end
55
55
 
56
+ # "Fails" a maybe given a certain condition. If the condition is `true`
57
+ # then Maybe(nil) will be returned.
58
+ #
59
+ # @see continue
60
+ def halt
61
+ and_then do |value|
62
+ value unless yield value
63
+ end
64
+ end
56
65
  end
57
66
  end
data/lib/ronad/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Ronad
2
- VERSION = "0.4.0"
2
+ VERSION = '0.5.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ronad
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Uri Gorelik
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-01-12 00:00:00.000000000 Z
11
+ date: 2018-02-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler