Skip to content

Commit

Permalink
fix: paynet bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
onurkanbakirci committed Dec 31, 2023
1 parent 306691f commit de795d6
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public PaynetPaymentIntegration(string secretKey, bool isInProduction = false) :
/// <returns><inheritdoc/></returns>
public async Task<NonSecurePaymentResponseModel> NonSecurePaymentAsync(NonSecurePaymentRequestModel nonSecurePaymentRequest)
{
return await InvokeRequestAsync<NonSecurePaymentResponseModel>((client, requestBody) => client.PostAsync(GetNonSecurePaymentUrl(), requestBody), nonSecurePaymentRequest);
return await InvokeRequestAsync<NonSecurePaymentRequestModel, NonSecurePaymentResponseModel>((client, requestBody) => client.PostAsync(GetNonSecurePaymentUrl(), requestBody), nonSecurePaymentRequest);
}

/// <summary>
Expand All @@ -32,7 +32,7 @@ public async Task<NonSecurePaymentResponseModel> NonSecurePaymentAsync(NonSecure
/// <returns><inheritdoc/></returns>
public async Task<SecurePaymentInitialResponseModel> SecurePaymentInitialAsync(SecurePaymentInitialRequestModel securePaymentInitialRequest)
{
return await InvokeRequestAsync<SecurePaymentInitialResponseModel>((client, requestBody) => client.PostAsync(GetSecurePaymentInitialUrl(), requestBody), securePaymentInitialRequest);
return await InvokeRequestAsync<SecurePaymentInitialRequestModel, SecurePaymentInitialResponseModel>((client, requestBody) => client.PostAsync(GetSecurePaymentInitialUrl(), requestBody), securePaymentInitialRequest);
}

/// <summary>
Expand All @@ -42,7 +42,7 @@ public async Task<SecurePaymentInitialResponseModel> SecurePaymentInitialAsync(S
/// <returns><inheritdoc/></returns>
public async Task<SecurePaymentChargeResponseModel> SecurePaymentChargeAsync(SecurePaymentChargeRequestModel securePaymentChargeRequest)
{
return await InvokeRequestAsync<SecurePaymentChargeResponseModel>((client, requestBody) => client.PostAsync(GetSecurePaymentChargeUrl(), requestBody), securePaymentChargeRequest);
return await InvokeRequestAsync<SecurePaymentChargeRequestModel, SecurePaymentChargeResponseModel>((client, requestBody) => client.PostAsync(GetSecurePaymentChargeUrl(), requestBody), securePaymentChargeRequest);
}

/// <summary>
Expand All @@ -52,7 +52,7 @@ public async Task<SecurePaymentChargeResponseModel> SecurePaymentChargeAsync(Sec
/// <returns><inheritdoc/></returns>
public async Task<RefundResponseModel> RefundAsync(RefundRequestModel refundRequest)
{
return await InvokeRequestAsync<RefundResponseModel>((client, requestBody) => client.PostAsync(GetRefundUrl(), requestBody), refundRequest);
return await InvokeRequestAsync<RefundRequestModel, RefundResponseModel>((client, requestBody) => client.PostAsync(GetRefundUrl(), requestBody), refundRequest);
}

/// <summary>
Expand All @@ -62,7 +62,7 @@ public async Task<RefundResponseModel> RefundAsync(RefundRequestModel refundRequ
/// <returns><inheritdoc/></returns>
public async Task<CancellationResponseModel> CancelAsync(CancellationRequestModel cancellationRequest)
{
return await InvokeRequestAsync<CancellationResponseModel>((client, requestBody) => client.PostAsync(GetCancelUrl(), requestBody), cancellationRequest);
return await InvokeRequestAsync<CancellationRequestModel, CancellationResponseModel>((client, requestBody) => client.PostAsync(GetCancelUrl(), requestBody), cancellationRequest);
}

/// <summary>
Expand All @@ -72,6 +72,6 @@ public async Task<CancellationResponseModel> CancelAsync(CancellationRequestMode
/// <returns><inheritdoc/></returns>
public async Task<CheckInstallmentResponseModel> CheckInstallmentAsync(CheckInstallmentRequestModel checkInstallmentRequest)
{
return await InvokeRequestAsync<CheckInstallmentResponseModel>((client, requestBody) => client.PostAsync(GetCheckInstallmentUrl(), requestBody), checkInstallmentRequest);
return await InvokeRequestAsync<CheckInstallmentRequestModel, CheckInstallmentResponseModel>((client, requestBody) => client.PostAsync(GetCheckInstallmentUrl(), requestBody), checkInstallmentRequest);
}
}

0 comments on commit de795d6

Please sign in to comment.