Skip to content

Commit 0630cfe

Browse files
committed
feat: optimization name
1 parent 7b7cc24 commit 0630cfe

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/services/completions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1543,12 +1543,12 @@ namespace ts.Completions {
15431543

15441544
function getVariableDeclaration(property: Node): VariableDeclaration | undefined {
15451545

1546-
const isArrowFunctionExpressionWithoutArrow = (node: Node) => {
1546+
const isArrowFunctionBody = (node: Node) => {
15471547
return node.parent && isArrowFunction(node.parent) && node.parent.body === node;
15481548
};
15491549

15501550
const variableDeclaration = findAncestor(property, (node) => {
1551-
if (isFunctionBlock(node) || isArrowFunctionExpressionWithoutArrow(node) || isBindingPattern(node)) {
1551+
if (isFunctionBlock(node) || isArrowFunctionBody(node) || isBindingPattern(node)) {
15521552
return "quit";
15531553
}
15541554

0 commit comments

Comments
 (0)