1
0
mirror of https://git.tuxpa.in/a/code-server.git synced 2024-12-27 04:35:25 +00:00

Cache extension tar requests

This commit is contained in:
Asher 2019-10-11 14:28:02 -05:00
parent 4ae2c81157
commit 567010e163
No known key found for this signature in database
GPG Key ID: D63C1EF81242354A

View File

@ -197,7 +197,7 @@ export abstract class Server {
protected async getTarredResource(...parts: string[]): Promise<Response> {
const filePath = this.ensureAuthorizedFilePath(...parts);
return { stream: tarFs.pack(filePath), filePath, mime: "application/tar" };
return { stream: tarFs.pack(filePath), filePath, mime: "application/tar", cache: true };
}
protected ensureAuthorizedFilePath(...parts: string[]): string {