Skip to content

Commit

Permalink
Remove read preference, as primary is the default
Browse files Browse the repository at this point in the history
  • Loading branch information
GromNaN committed May 22, 2024
1 parent 4b31535 commit 2c38c41
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions GridFSAdapterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -261,10 +261,7 @@ protected static function createFilesystemAdapter(): FilesystemAdapter
private static function getDatabase(): Database
{
$uri = getenv('MONGODB_URI') ?: 'mongodb://127.0.0.1:27017/';

$client = new Client($uri, [], [
'readPreference' => new ReadPreference(ReadPreference::PRIMARY),
]);
$client = new Client($uri);

return $client->selectDatabase(getenv('MONGODB_DATABASE') ?: 'flysystem_tests');
}
Expand Down

0 comments on commit 2c38c41

Please sign in to comment.