Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
Michael Telatynski 2024-11-26 17:28:32 +00:00
parent 9471feb69a
commit 638a9a53d3
No known key found for this signature in database
GPG key ID: A2B008A5F49F5D0D
2 changed files with 3 additions and 3 deletions

View file

@ -37,7 +37,7 @@ const config: Config = {
"recorderWorkletFactory": "<rootDir>/__mocks__/empty.js", "recorderWorkletFactory": "<rootDir>/__mocks__/empty.js",
"^fetch-mock$": "<rootDir>/node_modules/fetch-mock", "^fetch-mock$": "<rootDir>/node_modules/fetch-mock",
}, },
transformIgnorePatterns: ["/node_modules/(?!(mime|matrix-js-sdk)).+$"], transformIgnorePatterns: ["/node_modules/(?!(is-ip|mime|matrix-js-sdk)).+$"],
collectCoverageFrom: [ collectCoverageFrom: [
"<rootDir>/src/**/*.{js,ts,tsx}", "<rootDir>/src/**/*.{js,ts,tsx}",
// getSessionLock is piped into a different JS context via stringification, and the coverage functionality is // getSessionLock is piped into a different JS context via stringification, and the coverage functionality is

View file

@ -6,7 +6,7 @@ SPDX-License-Identifier: AGPL-3.0-only OR GPL-3.0-only
Please see LICENSE files in the repository root for full details. Please see LICENSE files in the repository root for full details.
*/ */
import isIp from "is-ip"; import { isIP } from "is-ip";
import * as utils from "matrix-js-sdk/src/utils"; import * as utils from "matrix-js-sdk/src/utils";
import { Room, MatrixClient, RoomStateEvent, EventType } from "matrix-js-sdk/src/matrix"; import { Room, MatrixClient, RoomStateEvent, EventType } from "matrix-js-sdk/src/matrix";
import { KnownMembership } from "matrix-js-sdk/src/types"; import { KnownMembership } from "matrix-js-sdk/src/types";
@ -491,7 +491,7 @@ function isHostnameIpAddress(hostname: string): boolean {
hostname = hostname.substring(1, hostname.length - 1); hostname = hostname.substring(1, hostname.length - 1);
} }
return isIp(hostname); return isIP(hostname);
} }
export const calculateRoomVia = (room: Room): string[] => { export const calculateRoomVia = (room: Room): string[] => {