fix: Use isValidPhoneNumber from libphonenumber-js/max (#23353)

* import from max

* fix

---------

Co-authored-by: Alex van Andel <[email protected]>
This commit is contained in:
Benny JooandAlex van Andel authored and GitHub committed 2025-10-29 08:13:41 +00:00
1 parent 268a142370
commit fdb0e5d004
14 files changed
+14 -14

No files matched your search

+1 -1
View File
@@ -2,7 +2,7 @@
* TODO: Consolidate this file with BookingLocationService and add tests
*/
import type { TFunction } from "i18next";
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { z } from "zod";
import { appStoreMetadata } from "@calcom/app-store/bookerAppsMetaData";
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import z from "zod";
import type { ALL_VIEWS } from "@calcom/features/form-builder/schema";
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import z from "zod";
import type { EventTypeCustomInput } from "@calcom/prisma/client";
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { v4 as uuidv4 } from "uuid";
import { replaceEventTypePlaceholders } from "@calcom/features/ee/workflows/components/agent-configuration/utils/promptUtils";
+1 -1
View File
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import z from "zod";
export const templateTypeEnum = z.enum(["CHECK_IN_APPOINTMENT", "CUSTOM_TEMPLATE"]);
@@ -1,5 +1,5 @@
import { zodResolver } from "@hookform/resolvers/zod";
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import type { Dispatch, SetStateAction } from "react";
import { useState } from "react";
import { Controller, useForm } from "react-hook-form";
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { z } from "zod";
export const agentSchema = z.object({
+1 -1
View File
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { z } from "zod";
import { TimeUnit, WorkflowActions, WorkflowTemplates, WorkflowTriggerEvents } from "@calcom/prisma/enums";
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { useRouter } from "next/navigation";
import { z } from "zod";
@@ -19,7 +19,7 @@ import {
Validate,
IsDefined,
} from "class-validator";
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import type { BookingLanguageType } from "./language";
import { BookingLanguage } from "./language";
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { z } from "zod";
export const ZDeleteInputSchema = z.object({
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { z } from "zod";
export const ZImportInputSchema = z.object({
@@ -1,4 +1,4 @@
import { isValidPhoneNumber } from "libphonenumber-js";
import { isValidPhoneNumber } from "libphonenumber-js/max";
import { z } from "zod";
export const ZUpdateInputSchema = z.object({