From 8b5b18c97ee7be5f2decf95242970150e224efbd Mon Sep 17 00:00:00 2001 From: "nicolas.dorier" Date: Thu, 23 Aug 2018 11:11:39 +0900 Subject: [PATCH] Make sure no trailing slash bug --- BTCPayServer/Controllers/StoresController.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/BTCPayServer/Controllers/StoresController.cs b/BTCPayServer/Controllers/StoresController.cs index c76cdd82b..cf95069d4 100644 --- a/BTCPayServer/Controllers/StoresController.cs +++ b/BTCPayServer/Controllers/StoresController.cs @@ -775,12 +775,12 @@ namespace BTCPayServer.Controllers const string DEFAULT_CURRENCY = "USD"; [Route("{storeId}/paybutton")] - public async Task PayButton() + public IActionResult PayButton() { var store = StoreData; var currencyDropdown = supportedCurrencies(store); - var appUrl = HttpContext.Request.GetAbsoluteRoot(); + var appUrl = HttpContext.Request.GetAbsoluteRoot().WithTrailingSlash(); var model = new PayButtonViewModel { Price = 10, @@ -788,7 +788,7 @@ namespace BTCPayServer.Controllers ButtonSize = 2, UrlRoot = appUrl, CurrencyDropdown = currencyDropdown, - PayButtonImageUrl = appUrl + "/img/paybutton/pay.png", + PayButtonImageUrl = appUrl + "img/paybutton/pay.png", StoreId = store.Id }; return View(model);