Skip to content

Commit

Permalink
Merge pull request #575 from mjcheetham/azrepos-list-fix
Browse files Browse the repository at this point in the history
Fix bug in Azure Repos binding `list` command
  • Loading branch information
mjcheetham authored Dec 20, 2021
2 parents b24086c + 350e5dd commit f28534a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ bool ExtractUserBinding(GitConfigurationEntry entry, IDictionary<string, string>
uri.Scheme == AzureDevOpsConstants.UrnScheme && uri.AbsolutePath.StartsWith(orgPrefix))
{
string entryOrgName = uri.AbsolutePath.Substring(orgPrefix.Length);
if (orgName is null || StringComparer.OrdinalIgnoreCase.Equals(entryOrgName, orgName))
if (string.IsNullOrWhiteSpace(orgName) || StringComparer.OrdinalIgnoreCase.Equals(entryOrgName, orgName))
{
dict[entryOrgName] = entry.Value;
}
Expand Down
2 changes: 1 addition & 1 deletion src/shared/Microsoft.AzureRepos/AzureReposHostProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,7 @@ static bool IsAzureDevOpsHttpRemote(string url, out Uri uri)
}
}

bool isFiltered = organization != null;
bool isFiltered = !string.IsNullOrWhiteSpace(organization);
string indent = isFiltered ? string.Empty : " ";

// Get the set of all organization names (organization names are not case sensitive)
Expand Down

0 comments on commit f28534a

Please sign in to comment.