diff --git a/src/Sql/Sql/ChangeLog.md b/src/Sql/Sql/ChangeLog.md index 96d4e23819a9..db1242c1eb63 100644 --- a/src/Sql/Sql/ChangeLog.md +++ b/src/Sql/Sql/ChangeLog.md @@ -20,6 +20,7 @@ ## Upcoming Release * Fixed issues where Set-AzSqlDatabaseAudit were not support Hyperscale database and database edition cannot be determined * Added MaintenanceConfigurationId to 'New-AzSqlInstance' and 'Set-AzSqlInstance' +* Fixed a bug in GetAzureSqlDatabaseReplicationLink.cs where PartnerServerName parameter was being checked for by value instead of key ## Version 2.11.1 * Fixed issue where New-AzSqlDatabaseExport fails if networkIsolation not specified [#13097] diff --git a/src/Sql/Sql/Replication/Cmdlet/GetAzureSqlDatabaseReplicationLink.cs b/src/Sql/Sql/Replication/Cmdlet/GetAzureSqlDatabaseReplicationLink.cs index af92fcbfa7f2..809a8e71e3cd 100644 --- a/src/Sql/Sql/Replication/Cmdlet/GetAzureSqlDatabaseReplicationLink.cs +++ b/src/Sql/Sql/Replication/Cmdlet/GetAzureSqlDatabaseReplicationLink.cs @@ -73,7 +73,7 @@ protected override IEnumerable GetEntity() { ICollection results; - if (MyInvocation.BoundParameters.ContainsKey(PartnerServerName) && !WildcardPattern.ContainsWildcardCharacters(PartnerServerName)) + if (MyInvocation.BoundParameters.ContainsKey(nameof(PartnerServerName)) && !WildcardPattern.ContainsWildcardCharacters(PartnerServerName)) { results = new List(); results.Add(ModelAdapter.GetLink(this.ResourceGroupName, this.ServerName, this.DatabaseName, this.PartnerResourceGroupName, this.PartnerServerName));