configure_me 0.3.1 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/configure_me/setting.rb +2 -1
- data/lib/configure_me/version.rb +1 -1
- metadata +3 -3
data/lib/configure_me/setting.rb
CHANGED
@@ -5,7 +5,7 @@ module ConfigureMe
|
|
5
5
|
def initialize(owner, name, type, *args)
|
6
6
|
options = args.extract_options!
|
7
7
|
|
8
|
-
@owner, @name, @type = owner, name.to_s
|
8
|
+
@owner, @name, @type = owner, name.to_s, type
|
9
9
|
@default = options.key?(:default) ? options[:default] : nil
|
10
10
|
end
|
11
11
|
|
@@ -20,6 +20,7 @@ module ConfigureMe
|
|
20
20
|
when :integer then value.to_i rescue value ? 1 : 0
|
21
21
|
when :float then value.to_f
|
22
22
|
when :date then ActiveRecord::ConnectionAdapters::Column.string_to_date(value)
|
23
|
+
when :boolean then ActiveRecord::ConnectionAdapters::Column.value_to_boolean(value)
|
23
24
|
else value
|
24
25
|
end
|
25
26
|
end
|
data/lib/configure_me/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: configure_me
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 3
|
9
|
-
-
|
10
|
-
version: 0.3.
|
9
|
+
- 2
|
10
|
+
version: 0.3.2
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Josh Williams
|