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.
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
* add .NET 5.0 support #286
* add .NET 5.0 support #286
Changes from all commits
fd755a8
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The contructor takes nullable DateTimes (
[...] , DateTime? dateOfSignature = null, [...]
so I guess the dates should be checked against null or does... != Datetime.MinValue
also check for null?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DateTime is a struct. It cannot be null. Also a warning appeared for this after add of .NET 5. I didn't check datatype of
dateOfSignature
. Nullable is not null, it is a class arround. So we have to check it by:dateOfSignature.HasValue
I will take care.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the feedback. The documentation states that for nullable types both, checking for null and checking for "HasValue" works: https://docs.microsoft.com/de-de/dotnet/csharp/language-reference/builtin-types/nullable-value-types
(Check second and third example.)
So I suggest we change the code to:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we have another issue here. The constructor does already convert the Nullable type to a regulare DateTime. In this case, nothing is assign and it will be the default value, which is probably
DateTime.MinValue
. This means there is no relation between your comment and this compare.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But it does so, only if dateOfSignature != null otherwise the conversion isn't run.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The contructor takes nullable DateTimes ([...] , DateTime? periodicFirstExecutionDate = null, [...] so I guess the dates should be checked against null or does ... != Datetime.MinValue also check for null?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DateTime is a struct. It cannot be null. Also a warning appeared for this after add of .NET 5. I didn't check datatype of
dateOfSignature
. Nullable is not null, it is a class arround. So we have to check it by:dateOfSignature.HasValue
I will take care.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The contructor takes nullable DateTimes ([...] , DateTime? periodicLastExecutionDate = null, [...] so I guess the dates should be checked against null or does ... != Datetime.MinValue also check for null?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
DateTime is a struct. It cannot be null. Also a warning appeared for this after add of .NET 5. I didn't check datatype of
dateOfSignature
. Nullable is not null, it is a class arround. So we have to check it by:dateOfSignature.HasValue
I will take care.
This file was deleted.