[SERVER-50840] Use 'number' alias in errors when 'number' is specified for $type Created: 09/Sep/20  Updated: 13/Oct/20  Resolved: 13/Oct/20

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Mihai Andrei Assignee: Mihai Andrei
Resolution: Won't Do Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Sprint: Query 2020-10-05, Query 2020-10-19
Participants:

 Description   

Currently, when the validator expression contains {$type: 'number'} (or, equivalently, the $jsonSchema keywords type or bsonType), the 'expectedTypes' field will report the types that are being aliased (i.e. double, long, int, decimal) and not the 'number' alias specified by the user. The error message might be clearer for $type if the 'number' alias is reported under 'expectedTypes' instead.


Generated at Thu Feb 08 05:23:44 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.