build: make eslint configuration use strict type checking
[poolifier.git] / src / worker / utils.ts
index b9372401ed881988d893248167d98a6b222c00be..d8c4c3e905318b3c485991155c65cfdc03f269a7 100644 (file)
@@ -2,7 +2,9 @@ import { isPlainObject } from '../utils.js'
 import type { TaskFunction } from './task-functions.js'
 import { KillBehaviors, type WorkerOptions } from './worker-options.js'
 
-export const checkValidWorkerOptions = (opts: WorkerOptions): void => {
+export const checkValidWorkerOptions = (
+  opts: WorkerOptions | undefined
+): void => {
   if (opts != null && !isPlainObject(opts)) {
     throw new TypeError('opts worker options parameter is not a plain object')
   }