You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The mapping logic only checks for the TextMarshaler interface of structs and pointers, but bson.ObjectId is type string.
The fix is to add another check when the underlying type is string, but in my opinion this is a bad idea right now. The reason is that for struct and pointer, there is no other obvious value for indexing, and combined with an explicit text field mapping, that is a very strong signal from the user expressing what they want. However, in this case we don't know that the user doesn't want to index the original string. I know people disagree, but I don't believe that the mere presence of TextMarshaler implies that that is the correct value for indexing.
The text was updated successfully, but these errors were encountered:
The mapping logic only checks for the TextMarshaler interface of structs and pointers, but bson.ObjectId is type string.
The fix is to add another check when the underlying type is string, but in my opinion this is a bad idea right now. The reason is that for struct and pointer, there is no other obvious value for indexing, and combined with an explicit text field mapping, that is a very strong signal from the user expressing what they want. However, in this case we don't know that the user doesn't want to index the original string. I know people disagree, but I don't believe that the mere presence of TextMarshaler implies that that is the correct value for indexing.
The text was updated successfully, but these errors were encountered: