diff --git a/gdb/mgodb/bson.go b/gdb/mgodb/types.go similarity index 79% rename from gdb/mgodb/bson.go rename to gdb/mgodb/types.go index 35cc0d7..0223e57 100644 --- a/gdb/mgodb/bson.go +++ b/gdb/mgodb/types.go @@ -10,6 +10,7 @@ package mgodb import ( "go.mongodb.org/mongo-driver/bson" "go.mongodb.org/mongo-driver/bson/primitive" + "go.mongodb.org/mongo-driver/mongo" ) // M is an unordered representation of a BSON document. @@ -25,3 +26,6 @@ type D = bson.D type A = bson.A type ObjectID = primitive.ObjectID + +// Collection is a handle to a MongoDB collection. It is safe for concurrent use by multiple goroutines. +type Collection = mongo.Collection