fix(core): update
This commit is contained in:
parent
365eea59bd
commit
77e69171e2
9977
package-lock.json
generated
9977
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
14
package.json
14
package.json
@ -12,19 +12,19 @@
|
||||
"build": "(tsbuild --web)"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@gitzone/tsbuild": "^2.1.24",
|
||||
"@gitzone/tstest": "^1.0.33",
|
||||
"@pushrocks/tapbundle": "^3.2.1",
|
||||
"tslint": "^6.1.2",
|
||||
"@gitzone/tsbuild": "^2.1.25",
|
||||
"@gitzone/tstest": "^1.0.52",
|
||||
"@pushrocks/tapbundle": "^3.2.9",
|
||||
"tslint": "^6.1.3",
|
||||
"tslint-config-prettier": "^1.18.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@pushrocks/qenv": "^4.0.10",
|
||||
"@pushrocks/smartpath": "^4.0.3",
|
||||
"@pushrocks/smartpromise": "^3.0.6",
|
||||
"@pushrocks/smartrx": "^2.0.15",
|
||||
"@pushrocks/streamfunction": "^1.0.24",
|
||||
"@types/minio": "^7.0.5",
|
||||
"@pushrocks/smartrx": "^2.0.19",
|
||||
"@pushrocks/streamfunction": "^2.0.1",
|
||||
"@types/minio": "^7.0.6",
|
||||
"minio": "^7.0.16"
|
||||
},
|
||||
"private": false,
|
||||
|
@ -79,9 +79,11 @@ tap.test('should correctly build paths for sub directories', async () => {
|
||||
tap.test('should list huge file directory', async () => {
|
||||
const servezoneBucket = await smartbucket.Bucket.getBucketByName(testSmartbucket, 'servezone');
|
||||
const servezoneBaseDirectory = await servezoneBucket.getBaseDirectory();
|
||||
this.brandfileDirectory = await servezoneBaseDirectory.getSubDirectoryByName('brandfiles');
|
||||
const files = servezoneBaseDirectory.listFiles();
|
||||
const brandfileDirectory = await servezoneBaseDirectory.getSubDirectoryByName('public/brandfiles');
|
||||
const files = await brandfileDirectory.listFiles();
|
||||
const directories = await brandfileDirectory.listDirectories();
|
||||
console.log(files);
|
||||
console.log(directories);
|
||||
});
|
||||
|
||||
tap.test('clean up directory style tests', async () => {
|
||||
|
@ -43,12 +43,20 @@ export class Directory {
|
||||
const parentDirectories = this.getParentDirectories();
|
||||
let basePath = '';
|
||||
for (const parentDir of parentDirectories) {
|
||||
if (parentDir.name === '') {
|
||||
if (!parentDir.name && !basePath) {
|
||||
basePath = this.name + '/';
|
||||
continue;
|
||||
}
|
||||
basePath = parentDir.name + '/' + this.name;
|
||||
if (parentDir.name && !basePath) {
|
||||
basePath = parentDir.name + '/' + this.name + '/';
|
||||
continue;
|
||||
}
|
||||
if (parentDir.name && basePath) {
|
||||
basePath = parentDir.name + '/' + basePath;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
console.log(basePath);
|
||||
return basePath;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user