mirror of
https://github.com/paper-trail-gem/paper_trail.git
synced 2022-11-09 11:33:19 -05:00
Fix create_versions
migration to support Ruby3 (#1366)
* Fix `create_versions` migration to support Ruby3 * Update changelog
This commit is contained in:
parent
81f935fb79
commit
3b8f55b3d1
3 changed files with 6 additions and 5 deletions
|
@ -42,7 +42,8 @@ recommendations of [keepachangelog.com](http://keepachangelog.com/).
|
|||
|
||||
### Fixed
|
||||
|
||||
- None
|
||||
- [#1366](https://github.com/paper-trail-gem/paper_trail/pull/1366) -
|
||||
Fixed a bug where the `create_versions` migration lead to a broken `db/schema.rb` for Ruby 3
|
||||
|
||||
### Dependencies
|
||||
|
||||
|
|
|
@ -53,9 +53,9 @@ module PaperTrail
|
|||
# See https://github.com/paper-trail-gem/paper_trail/issues/651
|
||||
def item_type_options
|
||||
if mysql?
|
||||
", { null: false, limit: 191 }"
|
||||
", null: false, limit: 191"
|
||||
else
|
||||
", { null: false }"
|
||||
", null: false"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -33,9 +33,9 @@ RSpec.describe PaperTrail::InstallGenerator, type: :generator do
|
|||
}.call
|
||||
expected_item_type_options = lambda {
|
||||
if described_class::MYSQL_ADAPTERS.include?(ActiveRecord::Base.connection.class.name)
|
||||
", { null: false, limit: 191 }"
|
||||
", null: false, limit: 191"
|
||||
else
|
||||
", { null: false }"
|
||||
", null: false"
|
||||
end
|
||||
}.call
|
||||
expect(destination_root).to(
|
||||
|
|
Loading…
Reference in a new issue