diff --git a/src/Api/Billing/Controllers/PreviewInvoiceController.cs b/src/Api/Billing/Controllers/PreviewInvoiceController.cs index 8cde24b4fe..d55e7299d6 100644 --- a/src/Api/Billing/Controllers/PreviewInvoiceController.cs +++ b/src/Api/Billing/Controllers/PreviewInvoiceController.cs @@ -58,6 +58,7 @@ public class PreviewInvoiceController( } [HttpPost("premium/subscriptions/upgrade")] + [InjectUser] public async Task PreviewPremiumUpgradeProrationAsync( [BindNever] User user, [FromBody] PreviewPremiumUpgradeProrationRequest request) diff --git a/src/Core/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommand.cs b/src/Core/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommand.cs index edb0255328..db5b907f8c 100644 --- a/src/Core/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommand.cs +++ b/src/Core/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommand.cs @@ -115,7 +115,6 @@ public class PreviewPremiumUpgradeProrationCommand( var options = new InvoiceCreatePreviewOptions { AutomaticTax = new InvoiceAutomaticTaxOptions { Enabled = true }, - Currency = "usd", Customer = user.GatewayCustomerId, Subscription = user.GatewaySubscriptionId, CustomerDetails = new InvoiceCustomerDetailsOptions diff --git a/test/Core.Test/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommandTests.cs b/test/Core.Test/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommandTests.cs index b1f60de67e..a681797a82 100644 --- a/test/Core.Test/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommandTests.cs +++ b/test/Core.Test/Billing/Premium/Commands/PreviewPremiumUpgradeProrationCommandTests.cs @@ -566,7 +566,6 @@ public class PreviewPremiumUpgradeProrationCommandTests await _stripeAdapter.Received(1).CreateInvoicePreviewAsync( Arg.Is(options => options.AutomaticTax.Enabled == true && - options.Currency == "usd" && options.Customer == "cus_123" && options.Subscription == "sub_123" && options.CustomerDetails.Address.Country == "US" &&