Fix bug where many-to-many fields cannot be accessed until the owner object has
a primary key