jagi / meteor-astronomy

Model layer for Meteor
https://atmospherejs.com/jagi/astronomy
MIT License
605 stars 66 forks source link

Index inheritance should not work if the field is a transient field #605

Closed talha-asad closed 7 years ago

talha-asad commented 7 years ago

Currently Astronomy will ensureIndex on a field if it uses a type of another Class and is marked as transient, this shouldn't be the case as the field is transient. I remember when we implemented this feature, we missed this edge-case.

cc @jagi

lukejagodzinski commented 7 years ago

Currently Astronomy will ensureIndex on a field if it uses a type of another Class and is marked as transient

Could you give some example? Because from this description I can say for sure that Astronomy by itself does not add indexes to transient fields and classes that are not stored in collections. So you probably used class as a nested field which is not intended to be used in that way.

talha-asad commented 7 years ago

If that's the case then we don't need this. I was recalling this from memory, closing.