Skip to content

Add obsolete message to alias that will be deleted in breaking change release #5298

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 19, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ public class AddAzureVirtualNetworkPeeringCommand : VirtualNetworkPeeringBase
HelpMessage = "Flag to allow the forwarded traffic from the VMs in the remote virtual network")]
public SwitchParameter AllowForwardedTraffic { get; set; }

[Obsolete("Add-AzureRmVirtualNetworkPeering: -AlloowGatewayTransit will be removed in an upcoming breaking change release. Please start using -AllowGatewayTransit to avoid breaking scripts.")]
[Alias("AlloowGatewayTransit")]
[Parameter(
Mandatory = false,
Expand Down Expand Up @@ -95,7 +96,9 @@ private PSVirtualNetworkPeering AddVirtualNetworkPeering()
}

vnetPeering.AllowVirtualNetworkAccess = !this.BlockVirtualNetworkAccess.IsPresent;
#pragma warning disable CS0618
vnetPeering.AllowGatewayTransit = this.AllowGatewayTransit;
#pragma warning restore CS0618
vnetPeering.AllowForwardedTraffic = this.AllowForwardedTraffic;
vnetPeering.UseRemoteGateways = this.UseRemoteGateways;

Expand Down