fix: fixing issue #19: Configuration throwing exception related to No… #20
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
After some inspecting, I was able to completely solve the exception for my example provided on issue #19.
This PR was the result.
The behavior before
On ParseFilter, called ReplaceComparisonAliases, then called GetAliasMatches.
On GetAliasMatches, in this line:
It added to
matcheseven when not specifying an alias forNotInOperator, becausealiases.NotInOperatorwasnull.Then, in the ReplaceComparisonAliases method, line
var escapedAlias = Regex.Escape(comparisonAliasMatch.Alias);throws the exception.The behavior now
As the NotInOperator is now assigned and not null, the condition on the if is not true (because I didn't provide a custom alias).
Now, the foreach doesn't throws an exception.
Tests
Before


After