From ce439211e2c6da8247509cd7c16365770614c946 Mon Sep 17 00:00:00 2001 From: akulsr0 Date: Fri, 12 Jul 2024 21:08:46 +0530 Subject: [PATCH] fix --- lib/rules/forbid-component-props.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/rules/forbid-component-props.js b/lib/rules/forbid-component-props.js index 67daadf9eb..20b11d9218 100644 --- a/lib/rules/forbid-component-props.js +++ b/lib/rules/forbid-component-props.js @@ -126,7 +126,7 @@ module.exports = { // Get config options having pattern const propNamePatternArray = Array.from(forbid.entries()).filter((propEntry) => propEntry[1].isPattern); // Match current prop with pattern options, return if matched - const propNamePattern = propNamePatternArray.find((propPatternVal) => minimatch(prop, propPatternVal[1])); + const propNamePattern = propNamePatternArray.find((propPatternVal) => minimatch(prop, propPatternVal[0])); // Get options for matched propNamePattern const propNamePatternOptions = propNamePattern && propNamePattern[1];