From fa6a1220785fb952f49c677e6931722c1c89e451 Mon Sep 17 00:00:00 2001 From: HenryBrown0 <26250092+HenryBrown0@users.noreply.github.com> Date: Fri, 26 Apr 2024 18:36:48 +0100 Subject: [PATCH] refactor: tidy boolean prop naming type arg --- lib/rules/boolean-prop-naming.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/rules/boolean-prop-naming.js b/lib/rules/boolean-prop-naming.js index 8ab514108f..81b178a9b3 100644 --- a/lib/rules/boolean-prop-naming.js +++ b/lib/rules/boolean-prop-naming.js @@ -250,8 +250,9 @@ module.exports = { return; } - const typeAnnotation = component.node.parent.id.typeAnnotation.typeAnnotation; - const annotationTypeArguments = propsUtil.getTypeArguments(typeAnnotation); + const annotationTypeArguments = propsUtil.getTypeArguments( + component.node.parent.id.typeAnnotation.typeAnnotation + ); if ( annotationTypeArguments && ( annotationTypeArguments.type === 'TSTypeParameterInstantiation'