Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PropertyValueTypeMismatchException #37

Open
ChinhDuong opened this issue Oct 16, 2018 · 5 comments
Open

PropertyValueTypeMismatchException #37

ChinhDuong opened this issue Oct 16, 2018 · 5 comments
Labels

Comments

@ChinhDuong
Copy link

I got PropertyValueTypeMismatchException when running following. I use .net 4.5.2. Could anyone help me to resolve it? Thanks in advance
class Person{
public long? Id { get; set; };
}

List people = new List<Person>{
new Person { Id = 1 },
new Person { Id = null },
new Person { Id = 2 },
}
var filter = new Filter<Person>();
long?[] idList = new long? { 1 };
filter.By("Id", Operation.In, idList);
var result = people.Where(filter); // throw PropertyValueTypeMismatchException

@dbelmont
Copy link
Owner

Hi @ChinhDuong,
Many thanks for using the project. And thanks for finding a bug! 🎉
I'll fix that and get back to you once it's done.
Cheers.

@dbelmont dbelmont added the bug label Nov 28, 2018
dbelmont added a commit that referenced this issue Jan 16, 2019
… - issue #36)

• Fixed issue #37 (exception thrown when using the `In` operator over a nullable property)
@dbelmont
Copy link
Owner

Hi @ChinhDuong,

I created a pre-release package at NuGet.org with the fix for this issue.
Would you mind checking that out and leaving a comment here to let me know if it's working correctly now?

Many thanks,
David

@ChinhDuong
Copy link
Author

ChinhDuong commented Jan 21, 2019 via email

@ChinhDuong
Copy link
Author

I tested the bug on 2.0.2-beta. it is not fixed

dbelmont added a commit that referenced this issue Feb 7, 2019
…a nullable property) for good [hopefully].
@dbelmont
Copy link
Owner

Hi @ChinhDuong,

Good news! I believe I got it right this time (even created a couple of tests specifically for that).

I just published a new version yesterday. Would you mind having a look at that?

Many thanks,
David

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants