]> git.openstreetmap.org Git - rails.git/commit
Specify inverse_of for trace tags and points
authorAndy Allan <git@gravitystorm.co.uk>
Wed, 23 Feb 2022 15:15:07 +0000 (15:15 +0000)
committerAndy Allan <git@gravitystorm.co.uk>
Wed, 23 Feb 2022 15:15:07 +0000 (15:15 +0000)
commit3cf3b3ce4e9551d532fee3b26c1f0a708cf53388
treeed9938e41b8804f0103abb15d014a7f28b7f2d2e
parent172a71e3f242f74a6eb1f7bb45fb4d5f3ddff5e7
Specify inverse_of for trace tags and points

Rails can't automatically detect bi-directional relationships when
`:foreign_key` is present. Adding the `inverse_of` helps when validating
traces and tags that haven't yet been saved.
app/models/trace.rb