enum_column 0.1.5 → 0.1.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,17 +1,15 @@
1
1
  module ActiveRecord
2
2
  module ConnectionAdapters # :nodoc:
3
3
  module Quoting
4
- alias __quote_enum quote
5
-
6
- # Quote a symbol as a normal string. This will support quoting of
7
- # enumerated values.
8
- def quote(value, column = nil)
9
- if !value.is_a? Symbol
10
- __quote_enum(value, column)
4
+ def quote_with_enum(value, column = nil)
5
+ if value.is_a?(Symbol)
6
+ quote_without_enum(value.to_s, column)
11
7
  else
12
- ActiveRecord::Base.send(:quote_bound_value, value.to_s)
8
+ quote_without_enum(value, column)
13
9
  end
14
10
  end
11
+
12
+ alias_method_chain :quote, :enum
15
13
  end
16
14
  end
17
15
  end
@@ -1,3 +1,3 @@
1
1
  module EnumColumn
2
- VERSION = "0.1.5"
2
+ VERSION = "0.1.6"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: enum_column
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 23
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 5
10
- version: 0.1.5
9
+ - 6
10
+ version: 0.1.6
11
11
  platform: ruby
12
12
  authors:
13
13
  - Stephan Kaag
@@ -16,7 +16,7 @@ autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
18
 
19
- date: 2011-03-24 00:00:00 +01:00
19
+ date: 2011-05-25 00:00:00 +02:00
20
20
  default_executable:
21
21
  dependencies: []
22
22