Skip to content

Commit 6fba0f2

Browse files
committed
updated dependencies
1 parent fff06db commit 6fba0f2

File tree

3 files changed

+1079
-1087
lines changed

3 files changed

+1079
-1087
lines changed

lib/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ function lookup(buffer: Buffer, filepath?: string): ISizeCalculationResult {
4343
* @param {String} filepath
4444
* @returns {Promise<Buffer>}
4545
*/
46-
async function asyncFileToBuffer(filepath: string) {
46+
async function asyncFileToBuffer(filepath: string): Promise<Buffer> {
4747
const handle = await fs.promises.open(filepath, 'r')
4848
const { size } = await handle.stat()
4949
if (size <= 0) {
@@ -62,7 +62,7 @@ async function asyncFileToBuffer(filepath: string) {
6262
* @param {String} filepath
6363
* @returns {Buffer}
6464
*/
65-
function syncFileToBuffer(filepath: string) {
65+
function syncFileToBuffer(filepath: string): Buffer {
6666
// read from the file, synchronously
6767
const descriptor = fs.openSync(filepath, 'r')
6868
const size = fs.fstatSync(descriptor).size
@@ -104,5 +104,5 @@ export function imageSize(input: Buffer | string, callback?: CallbackFn): ISizeC
104104
}
105105
}
106106

107-
export const setConcurrency = (c: number) => { queue.concurrency = c }
107+
export const setConcurrency = (c: number): void => { queue.concurrency = c }
108108
export const types = Object.keys(typeHandlers)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy