Skip to content

Commit

Permalink
Fix parsing inline listeners
Browse files Browse the repository at this point in the history
  • Loading branch information
anuruddhal committed Sep 26, 2023
1 parent e908fc1 commit f6bd1da
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,9 @@ private List<ListenerInfo> extractListeners(ServiceDeclarationNode serviceDeclar
}
listenerInfo = httpsListener.get();
} else {
if (expressionNode.kind() != SyntaxKind.EXPLICIT_NEW_EXPRESSION) {
return Collections.emptyList();
}
//Inline Listener
ExplicitNewExpressionNode refNode = (ExplicitNewExpressionNode) expressionNode;
FunctionArgumentNode functionArgumentNode = refNode.parenthesizedArgList().arguments().get(0);
Expand Down

0 comments on commit f6bd1da

Please sign in to comment.