Skip to content

Commit

Permalink
feat: update
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-yarmosh committed Jul 25, 2024
1 parent d25a5e2 commit 5830d55
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/helper/alt-ips-handler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,14 @@ export const apiConnectAltIpsHandler = async ({ token, socketId, ip }: { token:
.flatten()
.uniqBy('address')
.filter(address => !address.internal)
// .filter(address => !address.address.startsWith('fe80:'))
.filter(address => !address.address.startsWith('fe80:'))
.filter(address => !address.address.startsWith('169.254.'))
.value();

const results = await Promise.allSettled(addresses.map(({ address, family }) => sendToken(address, family === 'IPv6' ? 6 : 4, token, socketId)));

results.forEach((result) => {
if (result.status === 'rejected') {
console.log(result.reason.response?.body);
logger.error(result.reason);
logger.error(result.reason instanceof RequestError ? result.reason.message : result);
} else {
allIps.push(result.value);
Expand Down

0 comments on commit 5830d55

Please sign in to comment.