Skip to content

Conversation

axeh
Copy link
Owner

@axeh axeh commented Apr 7, 2022

No description provided.

}

if (extension == ".csproj" || extension == ".vbproj" || extension == ".vcxproj" || extension == ".oxygene" || extension == ".shfbproj")
if (extension == ".csproj" || extension == ".vbproj" || extension == ".vcxproj" || extension == ".oxygene" || extension == ".shfbproj" || extension == ".asdasd")
Copy link
Owner Author

@axeh axeh Apr 7, 2022

Choose a reason for hiding this comment

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

How about we extract extensions into hard-coded lists and use it? In that way, it will be easier to read.

public static IParser Parse(string fileName)
{
string extension = Path.GetExtension(fileName);
var n = extension.Length;
Copy link
Owner Author

Choose a reason for hiding this comment

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

We should use a more descriptive name for naming the variable. How about extensionLenght?

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

Successfully merging this pull request may close these issues.

1 participant