I have a model with a number of properties. One of those is a field named "developerId" that contains a string which has the same length and characteristics as a MongoDB ObjectId (it is in fact a stringified ObjectId).
When I query the model with the find() method in Node.js the query is updated before it is executed and the "developerId" value is converted to an ObjectId which then fails to match any strings in the database because they are strings, not ObjectIds.
{where: {developerId: '55118c5fc921fa170f05080b'}}
Is converted to:
{where: {developerId: ObjectId('55118c5fc921fa170f05080b')}}
The field is not an id field, is specified as a type: 'string' in the model json definition.
How do I switch off this auto-object-id behaviour so that I have control over Loopback's queries?