Skip to content

Commit 70a9507

Browse files
committed
Add deprecation warning for indexes_after_tables
1 parent 041591a commit 70a9507

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# lib/activerecord_clean_db_structure/config.rb
2+
require 'active_support/deprecation'
3+
4+
module ActiveRecordCleanDbStructure
5+
class Config
6+
attr_accessor :meta_tables_after_main
7+
8+
def indexes_after_tables=(value)
9+
ActiveSupport::Deprecation.warn(
10+
"[activerecord_clean_db_structure] `indexes_after_tables` is deprecated — use `meta_tables_after_main` instead"
11+
)
12+
self.meta_tables_after_main = value
13+
end
14+
15+
def indexes_after_tables
16+
meta_tables_after_main
17+
end
18+
end
19+
end

0 commit comments

Comments
 (0)