Skip to content

Commit 61f74cb

Browse files
committed
tech feedback
1 parent 83f8161 commit 61f74cb

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

source/includes/databases-collections.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ func main() {
4040
// start-access-collection
4141
collection := database.Collection("test_collection")
4242
// end-access-collection
43+
fmt.Println("Collection accessed:", collection.Name())
4344

4445
// Explicitly creates a collection in the database
4546
// start-create-collection
@@ -51,7 +52,7 @@ func main() {
5152

5253
// Retrieves information about each colllection in the database
5354
// start-list-collections
54-
cursor, err := database.ListCollections(context.TODO(), bson.M{}, options.ListCollections())
55+
cursor, err := database.ListCollections(context.TODO(), bson.D{})
5556
if err != nil {
5657
log.Fatalf("Failed to list collections: %v", err)
5758
}

0 commit comments

Comments
 (0)