mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-11 09:48:26 -04:00
Fixed a patreon reward bug and coinmarketcap ratelimit issue
This commit is contained in:
@@ -79,7 +79,7 @@ public class CryptoService : INService
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"",
|
"",
|
||||||
TimeSpan.FromHours(1));
|
TimeSpan.FromHours(2));
|
||||||
|
|
||||||
return JsonConvert.DeserializeObject<CryptoResponse>(fullStrData)?.Data ?? new();
|
return JsonConvert.DeserializeObject<CryptoResponse>(fullStrData)?.Data ?? new();
|
||||||
}
|
}
|
||||||
|
@@ -264,7 +264,7 @@ public class PatreonRewardsService : INService, IReadyExecutor
|
|||||||
var toAward = eligibleFor - usr.AmountRewardedThisMonth;
|
var toAward = eligibleFor - usr.AmountRewardedThisMonth;
|
||||||
|
|
||||||
usr.LastReward = now;
|
usr.LastReward = now;
|
||||||
usr.AmountRewardedThisMonth = toAward;
|
usr.AmountRewardedThisMonth = eligibleFor;
|
||||||
await uow.SaveChangesAsync();
|
await uow.SaveChangesAsync();
|
||||||
|
|
||||||
await _currency.AddAsync(userId, toAward, new("patreon", "update"));
|
await _currency.AddAsync(userId, toAward, new("patreon", "update"));
|
||||||
|
Reference in New Issue
Block a user