eslint-plugin-n 17.13.0 → 17.13.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/index.js CHANGED
@@ -86,8 +86,4 @@ const configs = {
86
86
  }
87
87
 
88
88
  /** @type {ESLint.Plugin & { configs: Configs }} */
89
- module.exports = {
90
- meta: base.meta,
91
- rules: base.rules,
92
- configs: configs,
93
- }
89
+ module.exports = Object.assign(base, { configs })
@@ -270,6 +270,13 @@ module.exports = class ImportTarget {
270
270
  this.resolveError = error.message
271
271
  }
272
272
 
273
+ /**
274
+ * @returns {void}
275
+ */
276
+ resetResolutionError() {
277
+ this.resolveError = null
278
+ }
279
+
273
280
  /**
274
281
  * Resolve the given id to file paths.
275
282
  * @returns {string | null} The resolved path.
@@ -324,7 +331,10 @@ module.exports = class ImportTarget {
324
331
 
325
332
  try {
326
333
  const resolved = requireResolve(baseDir, this.name)
327
- if (typeof resolved === "string") return resolved
334
+ if (typeof resolved === "string") {
335
+ this.resetResolutionError()
336
+ return resolved
337
+ }
328
338
  } catch (error) {
329
339
  this.handleResolutionError(error)
330
340
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-plugin-n",
3
- "version": "17.13.0",
3
+ "version": "17.13.2",
4
4
  "description": "Additional ESLint's rules for Node.js",
5
5
  "engines": {
6
6
  "node": "^18.18.0 || ^20.9.0 || >=21.1.0"