mirror of
https://github.com/ditkrg/validates_timeliness.git
synced 2026-01-23 06:16:44 +00:00
Add Ruby 3.0 compatibility
- Double splat `values` parameter when calling DateTimeValue
This commit is contained in:
parent
a0adda3eb2
commit
f25ab5671c
@ -16,6 +16,7 @@ rvm:
|
|||||||
- "2.5.8"
|
- "2.5.8"
|
||||||
- "2.6.6"
|
- "2.6.6"
|
||||||
- "2.7.2"
|
- "2.7.2"
|
||||||
|
- "3.0.0"
|
||||||
- ruby-head
|
- ruby-head
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
@ -33,6 +34,12 @@ jobs:
|
|||||||
gemfile: gemfiles/rails_5_1.gemfile
|
gemfile: gemfiles/rails_5_1.gemfile
|
||||||
- rvm: 2.7.2
|
- rvm: 2.7.2
|
||||||
gemfile: gemfiles/rails_5_2.gemfile
|
gemfile: gemfiles/rails_5_2.gemfile
|
||||||
|
- rvm: 3.0.0
|
||||||
|
gemfile: gemfiles/rails_5_0.gemfile
|
||||||
|
- rvm: 3.0.0
|
||||||
|
gemfile: gemfiles/rails_5_1.gemfile
|
||||||
|
- rvm: 3.0.0
|
||||||
|
gemfile: gemfiles/rails_5_2.gemfile
|
||||||
- rvm: ruby-head
|
- rvm: ruby-head
|
||||||
gemfile: gemfiles/rails_5_0.gemfile
|
gemfile: gemfiles/rails_5_0.gemfile
|
||||||
- rvm: ruby-head
|
- rvm: ruby-head
|
||||||
|
|||||||
@ -5,6 +5,7 @@
|
|||||||
in a request.
|
in a request.
|
||||||
* Add initializer to ensure Timeliness v0.4+ ambiguous date config is set
|
* Add initializer to ensure Timeliness v0.4+ ambiguous date config is set
|
||||||
correctly when using `use_euro_formats` or `remove_use_formats'.
|
correctly when using `use_euro_formats` or `remove_use_formats'.
|
||||||
|
* Add Ruby 3 compatibility
|
||||||
* Add Rails 6.1 compatibility
|
* Add Rails 6.1 compatibility
|
||||||
|
|
||||||
Breaking Changes
|
Breaking Changes
|
||||||
|
|||||||
@ -43,7 +43,7 @@ module ValidatesTimeliness
|
|||||||
values[POSITION.key(position.to_i)] = value.to_i
|
values[POSITION.key(position.to_i)] = value.to_i
|
||||||
end
|
end
|
||||||
|
|
||||||
DateTimeValue.new(values)
|
DateTimeValue.new(**values)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user