mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2024-11-10 01:02:30 +01:00
Remove extra hash
This commit is contained in:
parent
992c65a39d
commit
89e122210e
1 changed files with 1 additions and 2 deletions
|
@ -2,12 +2,11 @@ import axios from "axios";
|
|||
import { Logger } from "../utils/logger";
|
||||
import { config } from "../config";
|
||||
import { getIP } from "../utils/getIP";
|
||||
import { getHash } from "../utils/getHash";
|
||||
import { NextFunction, Request, Response } from "express";
|
||||
|
||||
export function userCounter(req: Request, res: Response, next: NextFunction): void {
|
||||
if (req.method !== "OPTIONS") {
|
||||
axios.post(`${config.userCounterURL}/api/v1/addIP?hashedIP=${getHash(getIP(req), 1)}`)
|
||||
axios.post(`${config.userCounterURL}/api/v1/addIP?hashedIP=${getIP(req)}`)
|
||||
.catch(() => Logger.debug(`Failing to connect to user counter at: ${config.userCounterURL}`));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue