Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Commit

Permalink
remove unnecessary check. anyMatch returns false for empty list.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rupal Mahajan committed Dec 12, 2020
1 parent 41e9d73 commit b3b8282
Showing 1 changed file with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,6 @@ private boolean isNonLiteralFunction(UnresolvedExpression expr) {
}
if (expr instanceof Function) {
List<? extends Node> children = expr.getChild();
// The base case for functions without input. e.g. PI(), NOW(), etc.
if (children.isEmpty()) {
return false;
}
return children.stream().anyMatch(child ->
isNonLiteralFunction((UnresolvedExpression) child));
}
Expand Down

0 comments on commit b3b8282

Please sign in to comment.