fix: ensure task function ops sync worker choice strategies
[poolifier.git] / src / pools / utils.ts
index 36bd8939fdf82155c208d966d502d3098f11ffe3..3fa17312d1fe24f54fb121eeda4d9dee6124e0c9 100644 (file)
@@ -89,14 +89,14 @@ export const checkDynamicPoolSize = (
 
 export const checkValidPriority = (priority: number | undefined): void => {
   if (priority != null && !Number.isSafeInteger(priority)) {
-    throw new TypeError(`Invalid priority '${priority}'`)
+    throw new TypeError(`Invalid property 'priority': '${priority}'`)
   }
   if (
     priority != null &&
     Number.isSafeInteger(priority) &&
     (priority < -20 || priority > 19)
   ) {
-    throw new RangeError('Property priority must be between -20 and 19')
+    throw new RangeError("Property 'priority' must be between -20 and 19")
   }
 }