Skip to content

Commit d4d8548

Browse files
committed
Update file sniffer.js for public class fields
1 parent 660810b commit d4d8548

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

file/sniffer.js

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,16 @@ const fileSignatures = {
4343
* numbers above), then the mimeType field will be set.
4444
*/
4545
class Node {
46-
/** @param {number} value */
46+
/** @type {string} */
47+
mimeType;
48+
49+
/** @type {Object<number, Node>} */
50+
children = {};
51+
52+
/** @param {number} value The byte that this Node points at. */
4753
constructor(value) {
54+
/** @type {number} */
4855
this.value = value;
49-
this.children = {};
50-
this.mimeType = undefined;
5156
}
5257
}
5358

@@ -98,7 +103,7 @@ export function initialize() {
98103
/**
99104
* Finds the likely MIME type represented by the ArrayBuffer.
100105
* @param {ArrayBuffer} ab
101-
* @return {string} The MIME type of the buffer, or undefined.
106+
* @returns {string} The MIME type of the buffer, or undefined.
102107
*/
103108
export function findMimeType(ab) {
104109
if (!root) {

0 commit comments

Comments
 (0)