From d6f0cb9441cd6dc9aa8adf7debbc3b05c173dd69 Mon Sep 17 00:00:00 2001 From: hiaga Date: Tue, 22 Dec 2020 11:58:54 +0530 Subject: [PATCH] fixing static analysis --- .../Vault/GetAzureRmRecoveryServicesVaultProperty.cs | 8 ++++---- .../Az.RecoveryServices/BreakingChangeIssues.csv | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) create mode 100644 tools/StaticAnalysis/Exceptions/Az.RecoveryServices/BreakingChangeIssues.csv diff --git a/src/RecoveryServices/RecoveryServices.Backup/Cmdlets/Vault/GetAzureRmRecoveryServicesVaultProperty.cs b/src/RecoveryServices/RecoveryServices.Backup/Cmdlets/Vault/GetAzureRmRecoveryServicesVaultProperty.cs index 963d24d083d8..5104482e6703 100644 --- a/src/RecoveryServices/RecoveryServices.Backup/Cmdlets/Vault/GetAzureRmRecoveryServicesVaultProperty.cs +++ b/src/RecoveryServices/RecoveryServices.Backup/Cmdlets/Vault/GetAzureRmRecoveryServicesVaultProperty.cs @@ -29,7 +29,7 @@ public class GetAzureRmRecoveryServicesVaultProperties : RSBackupVaultCmdletBase { [Parameter(Mandatory = false, ValueFromPipeline = false, Position = 1, HelpMessage = ParamHelpMsgs.Encryption.EncryptionSettings)] [ValidateNotNullOrEmpty] - public SwitchParameter EncryptionSettings; + public SwitchParameter EncryptionSetting; public override void ExecuteCmdlet() { @@ -39,10 +39,10 @@ public override void ExecuteCmdlet() string vaultName = resourceIdentifier.ResourceName; string resourceGroupName = resourceIdentifier.ResourceGroupName; - if(EncryptionSettings.IsPresent) + if(EncryptionSetting.IsPresent) { - BackupResourceEncryptionConfigResource vaultEncryptionSettings = ServiceClientAdapter.GetVaultEncryptionConfig(resourceGroupName, vaultName); - WriteObject(vaultEncryptionSettings); + BackupResourceEncryptionConfigResource vaultEncryptionSetting = ServiceClientAdapter.GetVaultEncryptionConfig(resourceGroupName, vaultName); + WriteObject(vaultEncryptionSetting); } else { diff --git a/tools/StaticAnalysis/Exceptions/Az.RecoveryServices/BreakingChangeIssues.csv b/tools/StaticAnalysis/Exceptions/Az.RecoveryServices/BreakingChangeIssues.csv new file mode 100644 index 000000000000..ee25f333b263 --- /dev/null +++ b/tools/StaticAnalysis/Exceptions/Az.RecoveryServices/BreakingChangeIssues.csv @@ -0,0 +1,2 @@ +"AssemblyFileName","ClassName","Target","Severity","ProblemId","Description","Remediation" +"Microsoft.Azure.PowerShell.Cmdlets.RecoveryServices.Backup.dll","Microsoft.Azure.Commands.RecoveryServices.Backup.Cmdlets.GetAzureRmRecoveryServicesVaultProperties","Get-AzRecoveryServicesVaultProperty","0","1020","The cmdlet 'Get-AzRecoveryServicesVaultProperty' no longer has output type 'Microsoft.Azure.Management.RecoveryServices.Backup.Models.BackupResourceVaultConfig'.","Make cmdlet 'Get-AzRecoveryServicesVaultProperty' return type 'Microsoft.Azure.Management.RecoveryServices.Backup.Models.BackupResourceVaultConfig'." \ No newline at end of file