date_time_precision 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -127,7 +127,7 @@ module DateTimePrecision
127
127
  # Redefine any conversion methods so precision is preserved
128
128
  [:to_date, :to_time, :to_datetime].each do |conversion_method|
129
129
  orig = :"orig_#{conversion_method}"
130
- if base.method_defined?(conversion_method) && !base.method_defined?(orig)
130
+ if base.method_defined?(conversion_method) && !base.instance_methods(false).map(&:to_sym).include?(orig)
131
131
  base.class_exec {
132
132
  alias_method orig, conversion_method
133
133
  define_method(conversion_method) {
@@ -1,3 +1,3 @@
1
1
  module DateTimePrecision
2
- VERSION = "0.3.0"
2
+ VERSION = "0.3.1"
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: date_time_precision
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 3
9
- - 0
10
- version: 0.3.0
9
+ - 1
10
+ version: 0.3.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - David Butler