mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 22:14:26 +01:00
use nameof
This commit is contained in:
@@ -673,7 +673,7 @@ namespace BTCPayServer.Controllers
|
||||
|
||||
private IActionResult ViewVault(WalletId walletId, PSBT psbt)
|
||||
{
|
||||
return View("WalletSendVault", new WalletSendVaultModel()
|
||||
return View(nameof(WalletSendVault), new WalletSendVaultModel()
|
||||
{
|
||||
WalletId = walletId.ToString(),
|
||||
PSBT = psbt.ToBase64(),
|
||||
@@ -683,7 +683,7 @@ namespace BTCPayServer.Controllers
|
||||
|
||||
[HttpPost]
|
||||
[Route("{walletId}/vault")]
|
||||
public async Task<IActionResult> SubmitVault([ModelBinder(typeof(WalletIdModelBinder))]
|
||||
public async Task<IActionResult> WalletSendVault([ModelBinder(typeof(WalletIdModelBinder))]
|
||||
WalletId walletId, WalletSendVaultModel model)
|
||||
{
|
||||
var network = NetworkProvider.GetNetwork<BTCPayNetwork>(walletId.CryptoCode);
|
||||
@@ -691,7 +691,7 @@ namespace BTCPayServer.Controllers
|
||||
if (newPSBT != null)
|
||||
{
|
||||
model.PSBT = newPSBT.ToBase64();
|
||||
return View("WalletSendVault", model);
|
||||
return View(nameof(WalletSendVault), model);
|
||||
}
|
||||
|
||||
return RedirectToWalletPSBTReady(model.PSBT);
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
</div>
|
||||
<div class="row">
|
||||
<div id="body" class="col-md-10">
|
||||
<form id="broadcastForm" asp-action="SubmitVault" asp-route-walletId="@this.Context.GetRouteValue("walletId")" method="post" style="display:none;">
|
||||
<form id="broadcastForm" asp-action="WalletSendVault" asp-route-walletId="@this.Context.GetRouteValue("walletId")" method="post" style="display:none;">
|
||||
<input type="hidden" id="WalletId" asp-for="WalletId" />
|
||||
<input type="hidden" id="PSBT" asp-for="PSBT" value="@Model.PSBT"/>
|
||||
<input type="hidden" asp-for="WebsocketPath" />
|
||||
|
||||
Reference in New Issue
Block a user