mirror of
https://github.com/denoland/deno.git
synced 2025-03-03 17:34:47 -05:00
parent
2e0ab295a3
commit
87d3b9b5cc
4 changed files with 17 additions and 9 deletions
|
@ -453,19 +453,24 @@ export class Untar {
|
|||
if (fileNamePrefix.byteLength > 0) {
|
||||
meta.fileName = decoder.decode(fileNamePrefix) + "/" + meta.fileName;
|
||||
}
|
||||
["fileMode", "mtime", "uid", "gid"].forEach(
|
||||
(["fileMode", "mtime", "uid", "gid"] as [
|
||||
"fileMode",
|
||||
"mtime",
|
||||
"uid",
|
||||
"gid"
|
||||
]).forEach(
|
||||
(key): void => {
|
||||
const arr = trim(header[key]);
|
||||
if (arr.byteLength > 0) {
|
||||
meta[key as keyof UntarOptions] = parseInt(decoder.decode(arr), 8);
|
||||
meta[key] = parseInt(decoder.decode(arr), 8);
|
||||
}
|
||||
}
|
||||
);
|
||||
["owner", "group"].forEach(
|
||||
(["owner", "group"] as ["owner", "group"]).forEach(
|
||||
(key): void => {
|
||||
const arr = trim(header[key]);
|
||||
if (arr.byteLength > 0) {
|
||||
meta[key as keyof UntarOptions] = decoder.decode(arr);
|
||||
meta[key] = decoder.decode(arr);
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
variables:
|
||||
DENO_VERSION: "v0.7.0"
|
||||
DENO_VERSION: "v0.8.0"
|
||||
TS_VERSION: "3.4.5"
|
||||
|
||||
# TODO Try to get eslint to run under Deno, like prettier
|
||||
|
|
|
@ -373,7 +373,8 @@ class Parser {
|
|||
}
|
||||
obj[k] = v;
|
||||
if (v instanceof Object) {
|
||||
this._propertyClean(v);
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
this._propertyClean(v as any);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -394,7 +395,8 @@ class Dumper {
|
|||
this.srcObject = srcObjc;
|
||||
}
|
||||
dump(): string[] {
|
||||
this.output = this._parse(this.srcObject);
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
this.output = this._parse(this.srcObject as any);
|
||||
this.output = this._format();
|
||||
return this.output;
|
||||
}
|
||||
|
@ -449,7 +451,7 @@ class Dumper {
|
|||
out.push("");
|
||||
out.push(this._header(path + prop));
|
||||
if (value) {
|
||||
const toParse: Record<string, unknown> = value;
|
||||
const toParse = value as Record<string, unknown>;
|
||||
out.push(...this._parse(toParse, `${path}${prop}.`));
|
||||
}
|
||||
// out.push(...this._parse(value, `${path}${prop}.`));
|
||||
|
|
|
@ -396,7 +396,8 @@ test(async function testReadRequestError(): Promise<void> {
|
|||
for (const test of testCases) {
|
||||
const reader = new BufReader(new StringReader(test.in));
|
||||
let err;
|
||||
let req;
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
let req: any;
|
||||
try {
|
||||
req = await readRequest(reader);
|
||||
} catch (e) {
|
||||
|
|
Loading…
Add table
Reference in a new issue