Skip to content

Commit

Permalink
Refactor IsDependenciesFile
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisyarbrough committed Feb 9, 2024
1 parent 87f25bf commit 22d1a09
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions source/AndroidResolver/src/XmlDependencies.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,13 @@ internal class XmlDependencies {
/// <summary>
/// Determines whether a filename matches an XML dependencies file.
/// </summary>
/// <param name="filename"></param>
/// <returns>true if it is a match, false otherwise.</returns>
internal static bool IsDependenciesFile(string filename) {
bool isInEditorFolder = filename.Contains("/Editor/") || filename.Contains(@"\Editor\");
return isInEditorFolder && filename.EndsWith("Dependencies.xml");
if (!filename.EndsWith("Dependencies.xml")) {
return false;
}

return filename.Contains("/Editor/") || filename.Contains(@"\Editor\");
}

/// <summary>
Expand Down

0 comments on commit 22d1a09

Please sign in to comment.