diff --git a/package-lock.json b/package-lock.json index 5f6c975..a46e95f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,15 +1,15 @@ { "name": "@apihub24/email-verification", - "version": "1.0.1", + "version": "1.0.2", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@apihub24/email-verification", - "version": "1.0.1", + "version": "1.0.2", "license": "MIT", "dependencies": { - "@apihub24/token-authentication": "^1.0.4", + "@apihub24/authentication": "^1.0.1", "@nestjs/common": "^11.1.6" }, "devDependencies": { @@ -35,25 +35,12 @@ "node": ">=6.0.0" } }, - "node_modules/@apihub24/repository": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@apihub24/repository/-/repository-1.0.3.tgz", - "integrity": "sha512-m2twcVPrdnKAcnNQFabGzQ/18/kQUEtuqAuSzVBTEc3mxBKBQ5ex1+Cx4JP/sZ1HqdS4GisFXDa8zfrnpdcLaA==", + "node_modules/@apihub24/authentication": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@apihub24/authentication/-/authentication-1.0.1.tgz", + "integrity": "sha512-nWw75ofQKHxE0dI7PzvNBQNcQrX/HSrzuAJTYNu42BoCROba1NUz8QAodTn5+3dIeQEzw127gtSb6D7yW0B8Jg==", "license": "MIT" }, - "node_modules/@apihub24/token-authentication": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@apihub24/token-authentication/-/token-authentication-1.0.4.tgz", - "integrity": "sha512-4v572LBbk9mDAthrYcI7wbm45gVki2GvZJUCKZPG7fYjR33M67+JtaVaLHy5jQ47QtOo1FF7cdF69wEq6nnn1g==", - "license": "MIT", - "dependencies": { - "@apihub24/repository": "^1.0.3", - "@nestjs/common": "^11.1.6", - "@nestjs/config": "^4.0.2", - "@nestjs/core": "^11.1.6", - "class-validator": "^0.14.2" - } - }, "node_modules/@babel/code-frame": { "version": "7.27.1", "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.27.1.tgz", @@ -1096,27 +1083,14 @@ } } }, - "node_modules/@nestjs/config": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/@nestjs/config/-/config-4.0.2.tgz", - "integrity": "sha512-McMW6EXtpc8+CwTUwFdg6h7dYcBUpH5iUILCclAsa+MbCEvC9ZKu4dCHRlJqALuhjLw97pbQu62l4+wRwGeZqA==", - "license": "MIT", - "dependencies": { - "dotenv": "16.4.7", - "dotenv-expand": "12.0.1", - "lodash": "4.17.21" - }, - "peerDependencies": { - "@nestjs/common": "^10.0.0 || ^11.0.0", - "rxjs": "^7.1.0" - } - }, "node_modules/@nestjs/core": { "version": "11.1.6", "resolved": "https://registry.npmjs.org/@nestjs/core/-/core-11.1.6.tgz", "integrity": "sha512-siWX7UDgErisW18VTeJA+x+/tpNZrJewjTBsRPF3JVxuWRuAB1kRoiJcxHgln8Lb5UY9NdvklITR84DUEXD0Cg==", + "dev": true, "hasInstallScript": true, "license": "MIT", + "peer": true, "dependencies": { "@nuxt/opencollective": "0.4.1", "fast-safe-stringify": "2.1.1", @@ -1184,7 +1158,9 @@ "version": "0.4.1", "resolved": "https://registry.npmjs.org/@nuxt/opencollective/-/opencollective-0.4.1.tgz", "integrity": "sha512-GXD3wy50qYbxCJ652bDrDzgMr3NFEkIS374+IgFQKkCvk9yiYcLvX2XDYr7UyQxf4wK0e+yqDYRubZ0DtOxnmQ==", + "dev": true, "license": "MIT", + "peer": true, "dependencies": { "consola": "^3.2.3" }, @@ -1386,7 +1362,9 @@ "version": "13.15.2", "resolved": "https://registry.npmjs.org/@types/validator/-/validator-13.15.2.tgz", "integrity": "sha512-y7pa/oEJJ4iGYBxOpfAKn5b9+xuihvzDVnC/OSvlVnGxVg0pOqmjiMafiJ1KVNQEaPZf9HsEp5icEwGg8uIe5Q==", - "license": "MIT" + "license": "MIT", + "optional": true, + "peer": true }, "node_modules/@types/yargs": { "version": "17.0.33", @@ -2037,6 +2015,8 @@ "resolved": "https://registry.npmjs.org/class-validator/-/class-validator-0.14.2.tgz", "integrity": "sha512-3kMVRF2io8N8pY1IFIXlho9r8IPUUIfHe2hYVtiebvAzU2XeQFXTv+XI4WX+TnXmtwXMDcjngcpkiPM0O9PvLw==", "license": "MIT", + "optional": true, + "peer": true, "dependencies": { "@types/validator": "^13.11.8", "libphonenumber-js": "^1.11.1", @@ -2170,7 +2150,9 @@ "version": "3.4.2", "resolved": "https://registry.npmjs.org/consola/-/consola-3.4.2.tgz", "integrity": "sha512-5IKcdX0nnYavi6G7TtOhwkYzyjfJlatbjMjuLSfE2kYT5pMDOilZ4OvMhi637CcDICTmz3wARPoyhqyX1Y+XvA==", + "dev": true, "license": "MIT", + "peer": true, "engines": { "node": "^14.18.0 || >=16.10.0" } @@ -2249,33 +2231,6 @@ "node": ">=8" } }, - "node_modules/dotenv": { - "version": "16.4.7", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.7.tgz", - "integrity": "sha512-47qPchRCykZC03FhkYAhrvwU4xDBFIj1QPqaarj6mdM/hgUzfPHcpkHJOn3mJAufFeeAxAzeGsr5X0M4k6fLZQ==", - "license": "BSD-2-Clause", - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://dotenvx.com" - } - }, - "node_modules/dotenv-expand": { - "version": "12.0.1", - "resolved": "https://registry.npmjs.org/dotenv-expand/-/dotenv-expand-12.0.1.tgz", - "integrity": "sha512-LaKRbou8gt0RNID/9RoI+J2rvXsBRPMV7p+ElHlPhcSARbCPDYcYG2s1TIzAfWv4YSgyY5taidWzzs31lNV3yQ==", - "license": "BSD-2-Clause", - "dependencies": { - "dotenv": "^16.4.5" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://dotenvx.com" - } - }, "node_modules/eastasianwidth": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", @@ -2424,7 +2379,9 @@ "version": "2.1.1", "resolved": "https://registry.npmjs.org/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz", "integrity": "sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA==", - "license": "MIT" + "dev": true, + "license": "MIT", + "peer": true }, "node_modules/fb-watchman": { "version": "2.0.2", @@ -3555,7 +3512,9 @@ "version": "1.12.13", "resolved": "https://registry.npmjs.org/libphonenumber-js/-/libphonenumber-js-1.12.13.tgz", "integrity": "sha512-QZXnR/OGiDcBjF4hGk0wwVrPcZvbSSyzlvkjXv5LFfktj7O2VZDrt4Xs8SgR/vOFco+qk1i8J43ikMXZoTrtPw==", - "license": "MIT" + "license": "MIT", + "optional": true, + "peer": true }, "node_modules/lines-and-columns": { "version": "1.2.4", @@ -3596,12 +3555,6 @@ "node": ">=8" } }, - "node_modules/lodash": { - "version": "4.17.21", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", - "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", - "license": "MIT" - }, "node_modules/lodash.memoize": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/lodash.memoize/-/lodash.memoize-4.1.2.tgz", @@ -3970,7 +3923,9 @@ "version": "8.2.0", "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-8.2.0.tgz", "integrity": "sha512-TdrF7fW9Rphjq4RjrW0Kp2AW0Ahwu9sRGTkS6bvDi0SCwZlEZYmcfDbEsTz8RVk0EHIS/Vd1bv3JhG+1xZuAyQ==", + "dev": true, "license": "MIT", + "peer": true, "engines": { "node": ">=16" } @@ -4891,6 +4846,8 @@ "resolved": "https://registry.npmjs.org/validator/-/validator-13.15.15.tgz", "integrity": "sha512-BgWVbCI72aIQy937xbawcs+hrVaN/CZ2UwutgaJ36hGqRrLNM+f5LUT/YPRbo8IV/ASeFzXszezV+y2+rq3l8A==", "license": "MIT", + "optional": true, + "peer": true, "engines": { "node": ">= 0.10" } diff --git a/package.json b/package.json index 3474517..cf00fcb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@apihub24/email-verification", - "version": "1.0.1", + "version": "1.0.2", "description": "", "main": "dist/index.js", "types": "./dist/index.d.ts", @@ -13,7 +13,7 @@ }, "dependencies": { "@nestjs/common": "^11.1.6", - "@apihub24/token-authentication": "^1.0.4" + "@apihub24/authentication": "^1.0.1" }, "devDependencies": { "rimraf": "^6.0.1", diff --git a/src/email.service.ts b/src/email.service.ts index fa679ca..977c7ae 100644 --- a/src/email.service.ts +++ b/src/email.service.ts @@ -1,7 +1,4 @@ -import { - IAccount, - IMailVerificationService, -} from "@apihub24/token-authentication"; +import { IAccount, IMailVerificationService } from "@apihub24/authentication"; import { Injectable } from "@nestjs/common"; @Injectable() diff --git a/src/email.verification.module.ts b/src/email.verification.module.ts index 086312a..fe8e889 100644 --- a/src/email.verification.module.ts +++ b/src/email.verification.module.ts @@ -1,15 +1,13 @@ import { DynamicModule, Module } from "@nestjs/common"; import { EmailService } from "./email.service"; - -export const APIHUB24_MAIL_SERVICE_INJECTION_KEY = - "@apihub24/mail_verification_service"; +import { APIHUB24_MAIL_SERVICE } from "@apihub24/authentication"; @Module({}) export class EmailVerificationModule { static forRoot(): DynamicModule { const providers = [ { - provide: APIHUB24_MAIL_SERVICE_INJECTION_KEY, + provide: APIHUB24_MAIL_SERVICE, useClass: EmailService, }, ];