mirror of
https://github.com/fullstack-cash/bch-api.git
synced 2026-09-22 09:12:05 -07:00
fix(origin): Testing origin screening
This commit is contained in:
@@ -122,6 +122,10 @@ class RateLimits {
|
||||
// Update the key so that rate limits track both the user and the resource.
|
||||
key = `${key}-${resource}`
|
||||
|
||||
const host = req.get('host')
|
||||
const origin = req.get('origin')
|
||||
console.log(`host: ${host}, origin: ${origin}`)
|
||||
|
||||
await _this.rateLimiter.consume(key, pointsToConsume)
|
||||
} catch (err) {
|
||||
// console.log('err: ', err)
|
||||
|
||||
Reference in New Issue
Block a user