Skip to content

Commit 4338b10

Browse files
committed
feedback
1 parent ef8dcb3 commit 4338b10

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

source/includes/connect/stable-api.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
<?php
2+
13
// start-specify-v1
24
$uri = "mongodb://<hostname>:<port>";
35

@@ -9,6 +11,8 @@
911
// start-stable-api-options
1012
$uri = "mongodb://<hostname>:<port>";
1113

12-
$driverOptions = ['serverApi' => new MongoDB\Driver\ServerApi('1', strict: true, deprecationErrors: true)];
14+
$serverApi = new MongoDB\Driver\ServerApi('1', strict: true, deprecationErrors: true);
15+
$driverOptions = ['serverApi' => $serverApi];
16+
1317
$client = new MongoDB\Client($uri, [], $driverOptions);
1418
// end-stable-api-options

0 commit comments

Comments
 (0)