Commit e564ccd
committed
Add spaces between functions and triggers in schema.rb
I've been dealing with the changes to schema_dumper in Rails 8.1 and
Senic 1.9 and found that it's most common for their methods not to emit
a newline after their last operation.
Hence I think it's safe to assume that functions() and triggers() should
emit a newline before their loops and within their loops, up to the last
iteration.
And, not having these functions emit a final newline holds with the pattern
used by the Rails and Scenic schema_dumpers.
I've tested this in my own apps with a patch on this gem and the spacing
is correct with the new Rails 8.1 schema changes (and with Scenic
emitting `create_view` statements before the `create_function` and
`create_trigger` statements).1 parent a58067d commit e564ccd
1 file changed
+7
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
24 | 26 | | |
| 27 | + | |
25 | 28 | | |
26 | | - | |
27 | | - | |
28 | 29 | | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
33 | | - | |
34 | | - | |
35 | | - | |
| 34 | + | |
36 | 35 | | |
37 | | - | |
| 36 | + | |
38 | 37 | | |
| 38 | + | |
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
| |||
0 commit comments