Skip to content

Commit 8e31a59

Browse files
ruby2_keyword removal final step
1 parent e078c8e commit 8e31a59

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

lib/safe-pg-migrations/plugins/strong_migrations_integration.rb

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,14 +62,12 @@ def strong_migration_available?
6262
method
6363
end
6464

65-
ruby2_keywords def add_column(table_name, *args)
66-
return super(table_name, *args) unless respond_to?(:safety_assured)
65+
def add_column(table_name, *args, **options)
66+
return super unless respond_to?(:safety_assured)
6767

68-
options = args.last.is_a?(Hash) ? args.last : {}
68+
return safety_assured { super } if options.fetch(:default_value_backfill, :auto) == :auto
6969

70-
return safety_assured { super(table_name, *args) } if options.fetch(:default_value_backfill, :auto) == :auto
71-
72-
super(table_name, *args)
70+
super
7371
end
7472
end
7573
end

0 commit comments

Comments
 (0)