fix(core): update
This commit is contained in:
@@ -234,14 +234,30 @@ export class Directory {
|
||||
return result;
|
||||
}
|
||||
|
||||
public async fastGetStream(pathArg: string): Promise<plugins.smartrx.rxjs.ReplaySubject<Buffer>> {
|
||||
const path = plugins.path.join(this.getBasePath(), pathArg);
|
||||
public fastGetStream(optionsArg: {
|
||||
path: string;
|
||||
}, typeArg: 'webstream'): Promise<ReadableStream>
|
||||
public async fastGetStream(optionsArg: {
|
||||
path: string;
|
||||
}, typeArg: 'nodestream'): Promise<plugins.stream.Readable>
|
||||
|
||||
/**
|
||||
* fastGetStream
|
||||
* @param optionsArg
|
||||
* @returns
|
||||
*/
|
||||
public async fastGetStream(optionsArg: { path: string; }, typeArg: 'webstream' | 'nodestream'): Promise<ReadableStream | plugins.stream.Readable>{
|
||||
const path = plugins.path.join(this.getBasePath(), optionsArg.path);
|
||||
const result = await this.bucketRef.fastGetStream({
|
||||
path,
|
||||
});
|
||||
path
|
||||
}, typeArg as any);
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* removes a file within the directory
|
||||
* @param optionsArg
|
||||
*/
|
||||
public async fastRemove(optionsArg: { path: string }) {
|
||||
const path = plugins.path.join(this.getBasePath(), optionsArg.path);
|
||||
await this.bucketRef.fastRemove({
|
||||
|
Reference in New Issue
Block a user