Merge pull request #1561 from 170210/fix_captcha
fix: set date in advance during faucet to prevent multiple requests from the same address
This commit is contained in:
commit
11ce1223f0
@ -83,9 +83,9 @@ export class Webserver {
|
||||
}
|
||||
|
||||
try {
|
||||
await faucet.credit(address, matchingDenom);
|
||||
// Count addresses to prevent draining
|
||||
this.addressCounter.set(address, new Date());
|
||||
await faucet.credit(address, matchingDenom);
|
||||
} catch (e) {
|
||||
console.error(e);
|
||||
throw new HttpError(500, "Sending tokens failed");
|
||||
|
||||
Loading…
Reference in New Issue
Block a user