From 9abd2db8ac027eaea4320b0b59ab386f2a84e7f9 Mon Sep 17 00:00:00 2001 From: prayansh_chhablani Date: Wed, 30 Oct 2024 16:16:32 +0530 Subject: [PATCH] fixing import errors --- src/resolvers/Query/me.ts | 2 +- .../roleDirectiveTransformer.spec.ts | 15 ++++++++++----- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/src/resolvers/Query/me.ts b/src/resolvers/Query/me.ts index b216765d1d..a45c111693 100644 --- a/src/resolvers/Query/me.ts +++ b/src/resolvers/Query/me.ts @@ -7,8 +7,8 @@ import { AppUserProfile, User, type InterfaceAppUserProfile, + type InterfaceUser } from "../../models"; -import type { InterfaceUser } from "../../models"; import type { QueryResolvers } from "../../types/generatedGraphQLTypes"; import { decryptEmail } from "../../utilities/encryption"; /** diff --git a/tests/directives/directiveTransformer/roleDirectiveTransformer.spec.ts b/tests/directives/directiveTransformer/roleDirectiveTransformer.spec.ts index 4e321f79bb..28d526ae83 100644 --- a/tests/directives/directiveTransformer/roleDirectiveTransformer.spec.ts +++ b/tests/directives/directiveTransformer/roleDirectiveTransformer.spec.ts @@ -18,17 +18,22 @@ import { connect, disconnect } from "../../helpers/db"; import type { TestUserType } from "../../helpers/userAndOrg"; import { encryptEmail } from "../../../src/utilities/encryption"; import { hashEmail } from "../../../src/utilities/hashEmail"; +import en from "../../../locales/en.json"; +import hi from "../../../locales/hi.json"; +import zh from "../../../locales/zh.json"; +import sp from "../../../locales/sp.json"; +import fr from "../../../locales/fr.json"; let MONGOOSE_INSTANCE: typeof mongoose; const app = express(); i18n.configure({ directory: `${__dirname}/locales`, staticCatalog: { - en: require("../../../locales/en.json"), - hi: require("../../../locales/hi.json"), - zh: require("../../../locales/zh.json"), - sp: require("../../../locales/sp.json"), - fr: require("../../../locales/fr.json"), + en, + hi, + zh, + sp, + fr, }, queryParameter: "lang", defaultLocale: appConfig.defaultLocale,