Skip to content

Commit

Permalink
Ensure getBucketInfos acces only mongo collections
Browse files Browse the repository at this point in the history
This is especially needed after PRA bootstrap was executed, as we
started using views in that context.

Issue: S3UTILS-178
  • Loading branch information
francoisferrand committed Oct 2, 2024
1 parent c680ebf commit ae6541c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion utils/S3UtilsMongoClient.js
Original file line number Diff line number Diff line change
Expand Up @@ -846,7 +846,7 @@ class S3UtilsMongoClient extends MongoClientInterface {
async getBucketInfos(log, cb) {
try {
const bucketInfos = [];
const collInfos = await this.db.listCollections().toArray();
const collInfos = await this.db.listCollections({ type: 'collection' }).toArray();
for (const value of collInfos) {
if (this._isSpecialCollection(value.name)) {
// skip
Expand Down

0 comments on commit ae6541c

Please sign in to comment.