Skip to content

Commit 6c54470

Browse files
Removing -vault parameter set from set-azurermsiterecoveryvaultcontext.
1 parent 312b5cd commit 6c54470

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

src/ResourceManager/SiteRecovery/Commands.SiteRecovery/Vault/SetAzureSiteRecoveryVaultSettings.cs

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,6 @@ public class SetAzureSiteRecoveryVaultSettings : SiteRecoveryCmdletBase
2828
{
2929
#region Parameters
3030

31-
/// <summary>
32-
/// Gets or sets vault Object.
33-
/// </summary>
34-
[Parameter(ParameterSetName = ASRParameterSets.Default, Mandatory = true)]
35-
[ValidateNotNullOrEmpty]
36-
public System.Object Vault { get; set; }
37-
3831
/// <summary>
3932
/// Gets or sets ASR vault Object.
4033
/// </summary>
@@ -61,33 +54,11 @@ public override void ExecuteSiteRecoveryCmdlet()
6154
switch (this.ParameterSetName)
6255
{
6356
case ASRParameterSets.ASRVault:
64-
this.WriteWarningWithTimestamp(
65-
string.Format(Properties.Resources.ParameterWillBeDeprecatedSoon,
66-
"ASRVault",
67-
"Vault"));
6857
this.SetASRVaultContext(this.ASRVault);
6958
break;
7059
case ASRParameterSets.ARSVault:
71-
this.WriteWarningWithTimestamp(
72-
string.Format(Properties.Resources.ParameterWillBeDeprecatedSoon,
73-
"ARSVault",
74-
"Vault"));
7560
this.SetARSVaultContext(this.ARSVault);
7661
break;
77-
case ASRParameterSets.Default:
78-
if (((PSObject)Vault).BaseObject is ASRVault)
79-
{
80-
this.SetASRVaultContext(((PSObject)Vault).BaseObject as ASRVault);
81-
}
82-
else if (((PSObject)Vault).BaseObject is ARSVault)
83-
{
84-
this.SetARSVaultContext(((PSObject)Vault).BaseObject as ARSVault);
85-
}
86-
else
87-
{
88-
throw new PSInvalidOperationException(Properties.Resources.InvalidVaultObject);
89-
}
90-
break;
9162
default:
9263
throw new PSInvalidOperationException(Properties.Resources.InvalidParameterSet);
9364
}

0 commit comments

Comments
 (0)