mirror of
https://github.com/Cameri/nostream.git
synced 2025-07-12 23:02:18 +02:00
fix: crash when payments are disabled
Signed-off-by: Ricardo Arturo Cabral Mejía <me@ricardocabral.io>
This commit is contained in:
@ -51,7 +51,7 @@ const createZebedeePaymentsProcessor = (settings: Settings): IPaymentsProcessor
|
|||||||
export const createPaymentsProcessor = (): IPaymentsProcessor => {
|
export const createPaymentsProcessor = (): IPaymentsProcessor => {
|
||||||
const settings = createSettings()
|
const settings = createSettings()
|
||||||
if (!settings.payments?.enabled) {
|
if (!settings.payments?.enabled) {
|
||||||
throw new Error('Unable to create payments processor: Setting payments.enabled is false')
|
return new NullPaymentsProcessor()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user