From e119dc823f8e5f31da592ffb08ab23c564900827 Mon Sep 17 00:00:00 2001 From: Kukks Date: Tue, 15 Jan 2019 09:46:07 +0100 Subject: [PATCH] fix app redirect to app instead of root url --- BTCPayServer/Controllers/AppsPublicController.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/BTCPayServer/Controllers/AppsPublicController.cs b/BTCPayServer/Controllers/AppsPublicController.cs index 4d97d60fe..f3a06ec49 100644 --- a/BTCPayServer/Controllers/AppsPublicController.cs +++ b/BTCPayServer/Controllers/AppsPublicController.cs @@ -19,6 +19,7 @@ using BTCPayServer.Services.Rates; using Ganss.XSS; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Cors; +using Microsoft.AspNetCore.Http.Extensions; using Microsoft.AspNetCore.Identity; using Microsoft.AspNetCore.Mvc; using Microsoft.EntityFrameworkCore; @@ -183,7 +184,7 @@ namespace BTCPayServer.Controllers NotificationURL = settings.NotificationUrl, FullNotifications = true, ExtendedNotifications = true, - RedirectURL = request.RedirectUrl, + RedirectURL = request.RedirectUrl ?? Request.GetDisplayUrl(), }, store, HttpContext.Request.GetAbsoluteRoot()); @@ -255,6 +256,7 @@ namespace BTCPayServer.Controllers OrderId = orderId, NotificationURL = notificationUrl, RedirectURL = redirectUrl, +// RedirectURL = redirectUrl ?? Request.GetDisplayUrl(), FullNotifications = true, }, store, HttpContext.Request.GetAbsoluteRoot()); return RedirectToAction(nameof(InvoiceController.Checkout), "Invoice", new { invoiceId = invoice.Data.Id });