Skip to content
This repository has been archived by the owner on Nov 20, 2023. It is now read-only.

Refactored ConfigFileFinder.cs #786

Merged
merged 5 commits into from
Dec 2, 2020
Merged

Refactored ConfigFileFinder.cs #786

merged 5 commits into from
Dec 2, 2020

Conversation

sirh3e
Copy link
Contributor

@sirh3e sirh3e commented Nov 13, 2020

No description provided.

@sirh3e sirh3e changed the title Features Refactored ConfigFileFinder.cs Nov 13, 2020
return false;
}
if (files.Length <= 1)
continue;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit prefer braces.

@sirh3e
Copy link
Contributor Author

sirh3e commented Nov 17, 2020

Added braces

@dasiths
Copy link
Member

dasiths commented Nov 19, 2020

There is something wrong with the build pipeline. The Build Windows task timed out on this PR as well. (This happened with with #767 too).

@@ -23,12 +23,14 @@ public static bool TryFindSupportedFile(string directoryPath, out string? filePa
return true;
}

if (files.Length > 1)
if (files.Length <= 1)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this condition only applicable when the length is 0? If so let's just make it if (files.Length == 0)

Copy link

@JunTaoLuo JunTaoLuo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One nit. Otherwise ready to merge.

@sirh3e
Copy link
Contributor Author

sirh3e commented Nov 21, 2020

@JunTaoLuo Yeah, you're right. It was late when I made the change. 😄

jkotalik pushed a commit that referenced this pull request Dec 1, 2020
* removed one intend

* changed 0 <= into == 0 because it can not be less then zero see also #786 for more informations

* added newline looks nicer

* removed intend if

* use of initalizes

* check for not null

* removed if nesteding

* check for null

* check for null

* remove if nesting

* added initializer

* use of language feature destruction key value

* removed unused () brakes

* use of switch statment instend of if
@JunTaoLuo JunTaoLuo merged commit 1e5ca5b into dotnet:master Dec 2, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants