serial_preference 0.2.0 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -38,6 +38,12 @@ module SerialPreference
38
38
  when :float, :real
39
39
  value.to_f
40
40
  when :boolean
41
+ return false if value == 0
42
+ return false if value == ""
43
+ return false if value == nil
44
+ return false if value.to_s.downcase == "false"
45
+ return false if value == "0"
46
+ return false if value.to_s.downcase == "no"
41
47
  !!value
42
48
  else
43
49
  nil
@@ -1,3 +1,3 @@
1
1
  module SerialPreference
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: serial_preference
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: