馃 Code Proposal
Improve gpgfs.getBucketIds() to be more robust and fully filter for valid bucket directories.
Verify:
- Path contains a valid bucket id
- Path is a directory
|
async getBucketIds(){ |
|
const bucketPaths = (await this.readDir('/buckets')) |
|
.map(item=>{ |
|
return item.replace('bucket-','') |
|
}) |
|
|
|
debug('found ids', bucketPaths) |
|
return bucketPaths |
|
} |
Motivation
馃 Code Proposal
Improve
gpgfs.getBucketIds()to be more robust and fully filter for valid bucket directories.Verify:
gpgfs/src/gpgfs.js
Lines 212 to 220 in fe51f8b
Motivation