Skip to content

Commit

Permalink
fix: More Offline Currency Payout Issues
Browse files Browse the repository at this point in the history
- Checking then unchecking the Offline Payout checkbox in the add or
  edit currency dialog results in the offline property being assigned to
  an empty string.
- This conflicts with the type definition of a Currency in
  currency-access.ts.
- So pay special attention to it potentially being an empty string.
- See issue crowbartools#2801
  • Loading branch information
phroggster committed Sep 11, 2024
1 parent 84dd4af commit 197fe92
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/backend/currency/currency-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ class CurrencyManager {
for (const currency of currencies) {
let basePayout = currency.payout;
if (!connectionManager.streamerIsOnline()) {
if (currency.offline == null || currency.offline === 0) {
if (currency.offline == null || (currency.offline as unknown) === "" || currency.offline === 0) {
continue;
}

Expand Down

0 comments on commit 197fe92

Please sign in to comment.