-
-
Notifications
You must be signed in to change notification settings - Fork 346
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 regexp second test for vref filespecs #1919
Conversation
remoteIndex = i; | ||
break; | ||
} | ||
else if (Regex.IsMatch(files[i].Name, internalFilePath)) |
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.
Consider instead if (internalFilePath.Equals(files[i]?.Name) || Regex.IsMatch(files[i]?.Name, internalFilePath))
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 thought about combining the tests, and it probably makes sense to do it that way. We're not cycling through the list a second time for the other test.
Hang on, what's the "?" you've got there?
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 "?" declares a nullable type, and means that the type before it may have a null value.
The schema is for .ckan files, not .netkan files, so this doesn't affect it. |
Closes #1918
Shouldn't impact any existing $vref filespecs, as they all have complete paths.