king_konf 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/king_konf/config.rb +2 -2
- data/lib/king_konf/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 70845cbc41ec59e96a4bf3e4894fdba569a4bea3
|
4
|
+
data.tar.gz: 3e00f88323c2316905fd645cfba2d6fd9d41bcbb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6f2feac2feef30ceb3440ff1dc50bd84bbcfb41a27c38382392b8799a2d15a7b6ec146fd6b93754399ab599031cce92e83da7e489a0aa267dfbde90760a81180
|
7
|
+
data.tar.gz: 94e6a8ac6583ac91e3038a3b96ac5ce86545764d606c384b950d0f388a94d17dec8524e152fdcec7ebb8b76e1045649f89ad6adc8268fe1e97056066de308790
|
data/lib/king_konf/config.rb
CHANGED
@@ -38,9 +38,9 @@ module KingKonf
|
|
38
38
|
|
39
39
|
def valid?(value)
|
40
40
|
case @type
|
41
|
-
when :string then value.is_a?(String)
|
41
|
+
when :string then value.is_a?(String) || value.nil?
|
42
42
|
when :list then value.is_a?(Array)
|
43
|
-
when :integer then value.is_a?(Integer)
|
43
|
+
when :integer then value.is_a?(Integer) || value.nil?
|
44
44
|
when :boolean then value == true || value == false
|
45
45
|
else raise "invalid type #{@type}"
|
46
46
|
end
|
data/lib/king_konf/version.rb
CHANGED