Skip to content

Commit 7c2322c

Browse files
committed
Fix compilation errors from merge
1 parent 7b5e304 commit 7c2322c

File tree

4 files changed

+7
-10
lines changed

4 files changed

+7
-10
lines changed

src/ResourceManager/Compute/Commands.Compute/Generated/Models/ComputeAutoMapperProfile.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,12 @@ private static void Initialize()
133133
cfg.CreateMap<TO.PSVirtualMachine, FROM.VirtualMachine>();
134134
cfg.CreateMap<FROM.RunCommandResult, TO.PSRunCommandResult>();
135135
cfg.CreateMap<TO.PSRunCommandResult, FROM.RunCommandResult>();
136+
cfg.CreateMap<FROM.RollingUpgradeStatusInfo, TO.PSRollingUpgradeStatusInfo>();
137+
cfg.CreateMap<TO.PSRollingUpgradeStatusInfo, FROM.RollingUpgradeStatusInfo>();
138+
cfg.CreateMap<FROM.VirtualMachineInstanceView, TO.PSVirtualMachineInstanceView>();
139+
cfg.CreateMap<TO.PSVirtualMachineInstanceView, FROM.VirtualMachineInstanceView>();
136140
});
137141

138-
Mapper.CreateMap<FROM.RollingUpgradeStatusInfo, TO.PSRollingUpgradeStatusInfo>();
139-
Mapper.CreateMap<TO.PSRollingUpgradeStatusInfo, FROM.RollingUpgradeStatusInfo>();
140-
Mapper.CreateMap<FROM.VirtualMachineInstanceView, TO.PSVirtualMachineInstanceView>();
141-
Mapper.CreateMap<TO.PSVirtualMachineInstanceView, FROM.VirtualMachineInstanceView>();
142142
_mapper = config.CreateMapper();
143143
}
144144
}

src/ResourceManager/Compute/Commands.Compute/Generated/VirtualMachineScaleSetRollingUpgrade/VirtualMachineScaleSetRollingUpgradeCancelMethod.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ public partial class StopAzureRmVmssRollingUpgrade : ComputeAutomationBaseCmdlet
104104
{
105105
protected override void ProcessRecord()
106106
{
107-
AutoMapper.Mapper.AddProfile<ComputeAutomationAutoMapperProfile>();
108107
ExecuteClientAction(() =>
109108
{
110109
if (ShouldProcess(this.VMScaleSetName, VerbsLifecycle.Stop)
@@ -117,7 +116,7 @@ protected override void ProcessRecord()
117116

118117
var result = VirtualMachineScaleSetRollingUpgradesClient.Cancel(resourceGroupName, vmScaleSetName);
119118
var psObject = new PSOperationStatusResponse();
120-
Mapper.Map<Azure.Management.Compute.Models.OperationStatusResponse, PSOperationStatusResponse>(result, psObject);
119+
ComputeAutoMapperProfile.Mapper.Map<Azure.Management.Compute.Models.OperationStatusResponse, PSOperationStatusResponse>(result, psObject);
121120
WriteObject(psObject);
122121
}
123122
});

src/ResourceManager/Compute/Commands.Compute/Generated/VirtualMachineScaleSetRollingUpgrade/VirtualMachineScaleSetRollingUpgradeGetLatestMethod.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,15 +104,14 @@ public partial class GetAzureRmVmssRollingUpgrade : ComputeAutomationBaseCmdlet
104104
{
105105
protected override void ProcessRecord()
106106
{
107-
AutoMapper.Mapper.AddProfile<ComputeAutomationAutoMapperProfile>();
108107
ExecuteClientAction(() =>
109108
{
110109
string resourceGroupName = this.ResourceGroupName;
111110
string vmScaleSetName = this.VMScaleSetName;
112111

113112
var result = VirtualMachineScaleSetRollingUpgradesClient.GetLatest(resourceGroupName, vmScaleSetName);
114113
var psObject = new PSRollingUpgradeStatusInfo();
115-
Mapper.Map<RollingUpgradeStatusInfo, PSRollingUpgradeStatusInfo>(result, psObject);
114+
ComputeAutoMapperProfile.Mapper.Map<RollingUpgradeStatusInfo, PSRollingUpgradeStatusInfo>(result, psObject);
116115
WriteObject(psObject);
117116
});
118117
}

src/ResourceManager/Compute/Commands.Compute/Generated/VirtualMachineScaleSetRollingUpgrade/VirtualMachineScaleSetRollingUpgradeStartOSUpgradeMethod.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ public partial class StartAzureRmVmssRollingOSUpgrade : ComputeAutomationBaseCmd
104104
{
105105
protected override void ProcessRecord()
106106
{
107-
AutoMapper.Mapper.AddProfile<ComputeAutomationAutoMapperProfile>();
108107
ExecuteClientAction(() =>
109108
{
110109
if (ShouldProcess(this.VMScaleSetName, VerbsLifecycle.Start))
@@ -114,7 +113,7 @@ protected override void ProcessRecord()
114113

115114
var result = VirtualMachineScaleSetRollingUpgradesClient.StartOSUpgrade(resourceGroupName, vmScaleSetName);
116115
var psObject = new PSOperationStatusResponse();
117-
Mapper.Map<Azure.Management.Compute.Models.OperationStatusResponse, PSOperationStatusResponse>(result, psObject);
116+
ComputeAutoMapperProfile.Mapper.Map<Azure.Management.Compute.Models.OperationStatusResponse, PSOperationStatusResponse>(result, psObject);
118117
WriteObject(psObject);
119118
}
120119
});

0 commit comments

Comments
 (0)