Skip to content

Commit b092dc2

Browse files
committed
Use Correct Types for Content
1 parent d448ea1 commit b092dc2

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/firebase.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -81,20 +81,20 @@ export default class FirebaseStorageAdapter extends BaseAdapter {
8181
}
8282
const filePath = this.getTargetDir(this.basePath);
8383
const rs = this.bucket.file(filePath).createReadStream();
84-
let contents: unknown = null;
84+
let fileContent: Buffer;
8585
return new Promise(function (resolve, reject) {
8686
rs.on('error', function (err) {
8787
return reject(err);
8888
});
8989
rs.on('data', function (data) {
90-
if (contents) {
91-
contents = data;
90+
if (fileContent) {
91+
fileContent = data;
9292
} else {
93-
contents = Buffer.concat([contents, data]);
93+
fileContent = Buffer.concat([fileContent, data]);
9494
}
9595
});
9696
rs.on('end', function () {
97-
return resolve(contents as any);
97+
return resolve(fileContent);
9898
});
9999
});
100100
}

0 commit comments

Comments
 (0)