Skip to content

Commit e225ea6

Browse files
committed
Swift: Remove redundant code.
1 parent dcd8810 commit e225ea6

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

swift/ql/lib/codeql/swift/regex/Regex.qll

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -476,12 +476,6 @@ private class NSStringCompareOptionsPotentialRegexEval extends PotentialRegexEva
476476
override predicate doesEvaluate() {
477477
// check there is flow from a `NSString.CompareOptions.regularExpression` value to an `options` argument;
478478
// if there isn't, the input won't be interpretted as a regular expression.
479-
exists(MemberRefExpr sourceValue |
480-
sourceValue
481-
.getMember()
482-
.(FieldDecl)
483-
.hasQualifiedName("NSString.CompareOptions", "regularExpression") and
484-
RegexEnableFlagFlow::flow(DataFlow::exprNode(sourceValue), optionsInput)
485-
)
479+
RegexEnableFlagFlow::flow(_, optionsInput)
486480
}
487481
}

0 commit comments

Comments
 (0)