Closed AlexMKotcz closed 7 months ago
whoops, thanks for this! if you change this to target main, i'll merge it in and do a patch release. I want you to get contribution credit this time!
annoying because i need a develop
or equivalent working branch for active and working doc separation, but then stuff normal PRs that i can't always merge in to a release right away won't get contribution... need to look into the right way to do this i'm sure i'm missing something simple.
either way. appreciate the assit and want to make sure you get credit this time!
Sure! Just did! Thanks!
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
matches
even when not specifying an alias forNotInOperator
, becausealiases.NotInOperator
wasnull
.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
![tests-after](https://github.com/pdevito3/QueryKit/assets/17142585/38b8ead0-b86f-47fc-aceb-43a736bebc51)