typeorm-polymorphic
typeorm-polymorphic copied to clipboard
fix: Take into account parent's primaryColumn config when fetching fr…
…om polymorphic child
Before, on a child repository's options, we didn't handle the case in which there were multiple parents which had different primaryColumn names
Now we take such configurations into account. Specifically, we fetch the metadata associated with the parent we are visiting and read its primaryColumn. This allows for multiple parents to have different ID names when such situations arise.