mirror of
https://github.com/bitwarden/server
synced 2025-12-25 04:33:26 +00:00
Revert filescoped (#2227)
* Revert "Add git blame entry (#2226)" This reverts commit239286737d. * Revert "Turn on file scoped namespaces (#2225)" This reverts commit34fb4cca2a.
This commit is contained in:
@@ -1,27 +1,28 @@
|
||||
using Bit.Core.Settings;
|
||||
|
||||
namespace Bit.Core.Utilities;
|
||||
|
||||
public class BitPayClient
|
||||
namespace Bit.Core.Utilities
|
||||
{
|
||||
private readonly BitPayLight.BitPay _bpClient;
|
||||
|
||||
public BitPayClient(GlobalSettings globalSettings)
|
||||
public class BitPayClient
|
||||
{
|
||||
if (CoreHelpers.SettingHasValue(globalSettings.BitPay.Token))
|
||||
private readonly BitPayLight.BitPay _bpClient;
|
||||
|
||||
public BitPayClient(GlobalSettings globalSettings)
|
||||
{
|
||||
_bpClient = new BitPayLight.BitPay(globalSettings.BitPay.Token,
|
||||
globalSettings.BitPay.Production ? BitPayLight.Env.Prod : BitPayLight.Env.Test);
|
||||
if (CoreHelpers.SettingHasValue(globalSettings.BitPay.Token))
|
||||
{
|
||||
_bpClient = new BitPayLight.BitPay(globalSettings.BitPay.Token,
|
||||
globalSettings.BitPay.Production ? BitPayLight.Env.Prod : BitPayLight.Env.Test);
|
||||
}
|
||||
}
|
||||
|
||||
public Task<BitPayLight.Models.Invoice.Invoice> GetInvoiceAsync(string id)
|
||||
{
|
||||
return _bpClient.GetInvoice(id);
|
||||
}
|
||||
|
||||
public Task<BitPayLight.Models.Invoice.Invoice> CreateInvoiceAsync(BitPayLight.Models.Invoice.Invoice invoice)
|
||||
{
|
||||
return _bpClient.CreateInvoice(invoice);
|
||||
}
|
||||
}
|
||||
|
||||
public Task<BitPayLight.Models.Invoice.Invoice> GetInvoiceAsync(string id)
|
||||
{
|
||||
return _bpClient.GetInvoice(id);
|
||||
}
|
||||
|
||||
public Task<BitPayLight.Models.Invoice.Invoice> CreateInvoiceAsync(BitPayLight.Models.Invoice.Invoice invoice)
|
||||
{
|
||||
return _bpClient.CreateInvoice(invoice);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user