mirror of
https://github.com/denoland/deno.git
synced 2025-09-28 21:24:48 +00:00
fix DenoBlob name (#5879)
This commit is contained in:
parent
55311c33c4
commit
fe7d6824c9
2 changed files with 14 additions and 1 deletions
|
@ -161,7 +161,7 @@ async function readBytes(
|
|||
// Ensures it does not impact garbage collection.
|
||||
export const blobBytesWeakMap = new WeakMap<Blob, Uint8Array>();
|
||||
|
||||
export class DenoBlob implements Blob {
|
||||
class DenoBlob implements Blob {
|
||||
[bytesSymbol]: Uint8Array;
|
||||
readonly size: number = 0;
|
||||
readonly type: string = "";
|
||||
|
@ -216,3 +216,11 @@ export class DenoBlob implements Blob {
|
|||
return readBytes(getStream(this[bytesSymbol]).getReader());
|
||||
}
|
||||
}
|
||||
|
||||
// we want the Base class name to be the name of the class.
|
||||
Object.defineProperty(DenoBlob, "name", {
|
||||
value: "Blob",
|
||||
configurable: true,
|
||||
});
|
||||
|
||||
export { DenoBlob };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue