Skip to content

Commit dbfcd89

Browse files
Merge pull request #481 from TransactionProcessing/codacy/high_fixes
fix of unused variable and other fixes
2 parents 1132070 + 51edfba commit dbfcd89

4 files changed

Lines changed: 6 additions & 8 deletions

File tree

TransactionProcessorACL.BusinessLogic/Services/TransactionProcessorACLApplicationService.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -516,9 +516,7 @@ public async Task<Result<MerchantResponse>> GetMerchant(Guid estateId,
516516
}
517517
Logger.LogWarning("in GetMerchant - Got Token");
518518
TokenResponse accessToken = accessTokenResult.Data;
519-
520-
ProcessLogonTransactionResponse response = null;
521-
519+
522520
Result<TransactionProcessor.DataTransferObjects.Responses.Merchant.MerchantResponse> result = await this.TransactionProcessorClient.GetMerchant(accessToken.AccessToken, estateId, merchantId, cancellationToken);
523521

524522
if (result.IsFailed)
@@ -581,7 +579,7 @@ public async Task<Result<MerchantResponse>> GetMerchant(Guid estateId,
581579
}
582580
}
583581

584-
if (result.Data.Contracts != null) {
582+
if (result.Data.Devices != null) {
585583
foreach (KeyValuePair<Guid, string> device in result.Data.Devices) {
586584
merchantResponse.Devices.Add(device.Key, device.Value);
587585
}

TransactionProcessorACL/Controllers/MerchantController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ public async Task<IActionResult> GetMerchant([FromQuery] String applicationVersi
240240
/// <summary>
241241
/// The controller name
242242
/// </summary>
243-
public const String ControllerName = "merchants";
243+
private const String ControllerName = "merchants";
244244

245245
/// <summary>
246246
/// The controller route

TransactionProcessorACL/Controllers/TransactionController.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ public async Task<IActionResult> PerformTransaction([FromBody] TransactionReques
105105
case SaleTransactionRequestMessage msg:
106106
TransactionCommands.ProcessSaleTransactionCommand saleCommand = this.CreateCommandFromRequest(claimsResult.Data.estateId, claimsResult.Data.merchantId, msg);
107107
Result<ProcessSaleTransactionResponse> saleResponse = await this.Mediator.Send(saleCommand, cancellationToken);
108-
// TODO: Handle the result
108+
109109
if (saleResponse.IsFailed)
110110
return saleResponse.ToActionResultX();
111111
dto = this.ModelFactory.ConvertFrom(saleResponse.Data);
@@ -201,7 +201,7 @@ private TransactionCommands.ProcessReconciliationCommand CreateCommandFromReques
201201
/// <summary>
202202
/// The controller name
203203
/// </summary>
204-
public const String ControllerName = "transactions";
204+
private const String ControllerName = "transactions";
205205

206206
/// <summary>
207207
/// The controller route

TransactionProcessorACL/Controllers/VoucherController.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ public async Task<IActionResult> RedeemVoucher([FromQuery] String voucherCode,
147147
/// <summary>
148148
/// The controller name
149149
/// </summary>
150-
public const String ControllerName = "vouchers";
150+
private const String ControllerName = "vouchers";
151151

152152
/// <summary>
153153
/// The controller route

0 commit comments

Comments
 (0)