Skip to content

Commit

Permalink
buffer: add JSDoc to blob bytes method
Browse files Browse the repository at this point in the history
PR-URL: #54117
Reviewed-By: Jake Yuesong Li <[email protected]>
Reviewed-By: Trivikram Kamat <[email protected]>
  • Loading branch information
RobertoSimonini1 authored and targos committed Aug 14, 2024
1 parent 358fdac commit 37631f8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/internal/blob.js
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,9 @@ class Blob {
return dec.decode(await this.arrayBuffer());
}

/**
* @returns {Promise<Uint8Array>}
*/
bytes() {
if (!isBlob(this))
throw new ERR_INVALID_THIS('Blob');
Expand Down

0 comments on commit 37631f8

Please sign in to comment.