summary refs log tree commit diff
path: root/util
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-10-11 15:13:16 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-10-11 15:13:16 +0200
commit833dcb7c3c8d3db916821533eee74934cc2fd82f (patch)
tree126003b57acb7c4ad5cee0728b2eef4085dfd838 /util
parentImplement GIFs (diff)
parentMerge pull request #435 from TheArcaneBrony/change-enums-to-number (diff)
downloadserver-833dcb7c3c8d3db916821533eee74934cc2fd82f.tar.xz
Merge branch 'master' into pr/Thesourtimes/430
Diffstat (limited to 'util')
-rw-r--r--util/ormconfig.json9
-rw-r--r--util/package-lock.json1192
-rw-r--r--util/package.json14
-rw-r--r--util/src/entities/AuditLog.ts5
-rw-r--r--util/src/entities/BaseClass.ts57
-rw-r--r--util/src/entities/Channel.ts2
-rw-r--r--util/src/entities/Config.ts2
-rw-r--r--util/src/entities/Emoji.ts14
-rw-r--r--util/src/entities/Guild.ts8
-rw-r--r--util/src/entities/Invite.ts11
-rw-r--r--util/src/entities/Message.ts5
-rw-r--r--util/src/entities/RateLimit.ts3
-rw-r--r--util/src/entities/ReadState.ts13
-rw-r--r--util/src/entities/Relationship.ts2
-rw-r--r--util/src/entities/Sticker.ts4
-rw-r--r--util/src/entities/TeamMember.ts2
-rw-r--r--util/src/entities/User.ts8
-rw-r--r--util/src/entities/Webhook.ts5
-rw-r--r--util/src/index.ts6
-rw-r--r--util/src/interfaces/Event.ts8
-rw-r--r--util/src/migrations/1633864260873-EmojiRoles.ts13
-rw-r--r--util/src/migrations/1633864669243-EmojiUser.ts23
-rw-r--r--util/src/migrations/1633881705509-VanityInvite.ts17
-rw-r--r--util/src/migrations/migrate_db_engine.js106
-rw-r--r--util/src/migrations/migrate_db_engine.ts129
-rw-r--r--util/src/util/Config.ts1
-rw-r--r--util/src/util/Rights.ts10
-rw-r--r--util/src/util/TraverseDirectory.ts10
-rw-r--r--util/src/util/cdn.ts2
-rw-r--r--util/src/util/index.ts1
-rw-r--r--util/tsconfig.json4
31 files changed, 451 insertions, 1235 deletions
diff --git a/util/ormconfig.json b/util/ormconfig.json
new file mode 100644
index 00000000..c5587b8e
--- /dev/null
+++ b/util/ormconfig.json
@@ -0,0 +1,9 @@
+{
+	"type": "sqlite",
+	"database": "../bundle/database.db",
+	"migrations": ["src/migrations/*.ts"],
+	"entities": ["src/entities/*.ts"],
+	"cli": {
+		"migrationsDir": "src/migrations"
+	}
+}
diff --git a/util/package-lock.json b/util/package-lock.json
index 0ce50636..5f136dbc 100644
--- a/util/package-lock.json
+++ b/util/package-lock.json
@@ -10,11 +10,7 @@
 			"hasInstallScript": true,
 			"license": "GPLV3",
 			"dependencies": {
-				"ajv": "^8.6.2",
 				"amqplib": "^0.8.0",
-				"class-validator": "^0.13.1",
-				"dot-prop": "^6.0.1",
-				"env-paths": "^2.2.1",
 				"jsonwebtoken": "^8.5.1",
 				"lambert-server": "^1.2.11",
 				"missing-native-js-functions": "^1.2.17",
@@ -25,21 +21,18 @@
 				"pg": "^8.7.1",
 				"reflect-metadata": "^0.1.13",
 				"sqlite3": "^5.0.2",
-				"tsconfig-paths": "^3.11.0",
 				"typeorm": "^0.2.37",
 				"typescript": "^4.4.2",
 				"typescript-json-schema": "^0.50.1"
 			},
 			"devDependencies": {
-				"@swc/cli": "^0.1.51",
-				"@swc/core": "^1.2.93",
 				"@types/amqplib": "^0.8.1",
 				"@types/jsonwebtoken": "^8.5.0",
-				"@types/mongoose-autopopulate": "^0.10.1",
 				"@types/multer": "^1.4.7",
 				"@types/node": "^14.17.9",
 				"@types/node-fetch": "^2.5.12",
-				"jest": "^27.0.6"
+				"jest": "^27.0.6",
+				"ts-node": "^10.2.1"
 			}
 		},
 		"node_modules/@babel/code-frame": {
@@ -674,6 +667,27 @@
 			"integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==",
 			"dev": true
 		},
+		"node_modules/@cspotcode/source-map-consumer": {
+			"version": "0.8.0",
+			"resolved": "https://registry.npmjs.org/@cspotcode/source-map-consumer/-/source-map-consumer-0.8.0.tgz",
+			"integrity": "sha512-41qniHzTU8yAGbCp04ohlmSrZf8bkf/iJsl3V0dRGsQN/5GFfx+LbCSsCpp2gqrqjTVg/K6O8ycoV35JIwAzAg==",
+			"dev": true,
+			"engines": {
+				"node": ">= 12"
+			}
+		},
+		"node_modules/@cspotcode/source-map-support": {
+			"version": "0.6.1",
+			"resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.6.1.tgz",
+			"integrity": "sha512-DX3Z+T5dt1ockmPdobJS/FAsQPW4V4SrWEhD2iYQT2Cb2tQsiMnYxrcUH9By/Z3B+v0S5LMBkQtV/XOBbpLEOg==",
+			"dev": true,
+			"dependencies": {
+				"@cspotcode/source-map-consumer": "0.8.0"
+			},
+			"engines": {
+				"node": ">=12"
+			}
+		},
 		"node_modules/@istanbuljs/load-nyc-config": {
 			"version": "1.1.0",
 			"resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz",
@@ -979,56 +993,6 @@
 				"node": "^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0"
 			}
 		},
-		"node_modules/@napi-rs/triples": {
-			"version": "1.0.3",
-			"resolved": "https://registry.npmjs.org/@napi-rs/triples/-/triples-1.0.3.tgz",
-			"integrity": "sha512-jDJTpta+P4p1NZTFVLHJ/TLFVYVcOqv6l8xwOeBKNPMgY/zDYH/YH7SJbvrr/h1RcS9GzbPcLKGzpuK9cV56UA==",
-			"dev": true
-		},
-		"node_modules/@node-rs/helper": {
-			"version": "1.2.1",
-			"resolved": "https://registry.npmjs.org/@node-rs/helper/-/helper-1.2.1.tgz",
-			"integrity": "sha512-R5wEmm8nbuQU0YGGmYVjEc0OHtYsuXdpRG+Ut/3wZ9XAvQWyThN08bTh2cBJgoZxHQUPtvRfeQuxcAgLuiBISg==",
-			"dev": true,
-			"dependencies": {
-				"@napi-rs/triples": "^1.0.3"
-			}
-		},
-		"node_modules/@nodelib/fs.scandir": {
-			"version": "2.1.5",
-			"resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
-			"integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
-			"dev": true,
-			"dependencies": {
-				"@nodelib/fs.stat": "2.0.5",
-				"run-parallel": "^1.1.9"
-			},
-			"engines": {
-				"node": ">= 8"
-			}
-		},
-		"node_modules/@nodelib/fs.stat": {
-			"version": "2.0.5",
-			"resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
-			"integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==",
-			"dev": true,
-			"engines": {
-				"node": ">= 8"
-			}
-		},
-		"node_modules/@nodelib/fs.walk": {
-			"version": "1.2.8",
-			"resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
-			"integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
-			"dev": true,
-			"dependencies": {
-				"@nodelib/fs.scandir": "2.1.5",
-				"fastq": "^1.6.0"
-			},
-			"engines": {
-				"node": ">= 8"
-			}
-		},
 		"node_modules/@sinonjs/commons": {
 			"version": "1.8.3",
 			"resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-1.8.3.tgz",
@@ -1052,265 +1016,6 @@
 			"resolved": "https://registry.npmjs.org/@sqltools/formatter/-/formatter-1.2.3.tgz",
 			"integrity": "sha512-O3uyB/JbkAEMZaP3YqyHH7TMnex7tWyCbCI4EfJdOCoN6HIhqdJBWTM6aCCiWQ/5f5wxjgU735QAIpJbjDvmzg=="
 		},
-		"node_modules/@swc/cli": {
-			"version": "0.1.51",
-			"resolved": "https://registry.npmjs.org/@swc/cli/-/cli-0.1.51.tgz",
-			"integrity": "sha512-7eqZGpkI4QOYfF+9FV4xpT/V/LSRDs5OMJcm4Z46JnPMvv+sxumAFdCe1hHRzHgnzwis9OtjI8Tt3Srf9JudQw==",
-			"dev": true,
-			"dependencies": {
-				"commander": "^7.1.0",
-				"fast-glob": "^3.2.5",
-				"slash": "3.0.0",
-				"source-map": "^0.7.3"
-			},
-			"bin": {
-				"spack": "bin/spack.js",
-				"swc": "bin/swc.js"
-			},
-			"engines": {
-				"node": ">= 12.13"
-			},
-			"peerDependencies": {
-				"@swc/core": "^1.2.66",
-				"chokidar": "^3.5.1"
-			},
-			"peerDependenciesMeta": {
-				"chokidar": {
-					"optional": true
-				}
-			}
-		},
-		"node_modules/@swc/cli/node_modules/source-map": {
-			"version": "0.7.3",
-			"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz",
-			"integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==",
-			"dev": true,
-			"engines": {
-				"node": ">= 8"
-			}
-		},
-		"node_modules/@swc/core": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core/-/core-1.2.93.tgz",
-			"integrity": "sha512-Lx9I+9GfUl2Mb7r23MVbSkc+NZE0+xZ4Xh787D1b82KMeFLz7QgYe4cNM9SzTjV/VlSQyNTVlzjES7ZThIUvtA==",
-			"dev": true,
-			"dependencies": {
-				"@node-rs/helper": "^1.0.0"
-			},
-			"engines": {
-				"node": ">=10"
-			},
-			"funding": {
-				"type": "opencollective",
-				"url": "https://opencollective.com/swc"
-			},
-			"optionalDependencies": {
-				"@swc/core-android-arm64": "1.2.93",
-				"@swc/core-darwin-arm64": "1.2.93",
-				"@swc/core-darwin-x64": "1.2.93",
-				"@swc/core-freebsd-x64": "1.2.93",
-				"@swc/core-linux-arm-gnueabihf": "1.2.93",
-				"@swc/core-linux-arm64-gnu": "1.2.93",
-				"@swc/core-linux-arm64-musl": "1.2.93",
-				"@swc/core-linux-x64-gnu": "1.2.93",
-				"@swc/core-linux-x64-musl": "1.2.93",
-				"@swc/core-win32-arm64-msvc": "1.2.93",
-				"@swc/core-win32-ia32-msvc": "1.2.93",
-				"@swc/core-win32-x64-msvc": "1.2.93"
-			}
-		},
-		"node_modules/@swc/core-android-arm64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-android-arm64/-/core-android-arm64-1.2.93.tgz",
-			"integrity": "sha512-3F5A7QNR5+MI64W20QBADU0Z6knt8kJOxIoKw4Vuk7JQ6k0nnMemio3LtusHgAVZLXq0wMILZ4kv/+qnRzWb7A==",
-			"cpu": [
-				"arm64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"android"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-darwin-arm64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-darwin-arm64/-/core-darwin-arm64-1.2.93.tgz",
-			"integrity": "sha512-a8tu9WCtnjiuKTscUu8N9z/vVuIldwo5US4WfYi2dtQNgf21n1ZKxwvsZzRz6mEC86zVE0k9pmslwEtMuuCJog==",
-			"cpu": [
-				"arm64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"darwin"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-darwin-x64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-darwin-x64/-/core-darwin-x64-1.2.93.tgz",
-			"integrity": "sha512-ga8bpjauZYHWMjuPKcqOZFSgStvveMc/J7yqIlr9sF2pOr7Rt/MKLO4Ups95A2Aay90aCF9cPKQDtX71PmdlVw==",
-			"cpu": [
-				"x64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"darwin"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-freebsd-x64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-freebsd-x64/-/core-freebsd-x64-1.2.93.tgz",
-			"integrity": "sha512-qDBEZqHh6C2AMaxjdm/Am8MUwN94RS3na9VLYDMGUkgs2yvnSADfx7JOyZEJT1Ot7FZEuyGXcSfomUzNCU/5kw==",
-			"cpu": [
-				"x64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"freebsd"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-linux-arm-gnueabihf": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.2.93.tgz",
-			"integrity": "sha512-KlJsXOcZpuHXU8hMVDXfSyBQ9fdUpzwDV1JKpfIehG+P2kRdCbiN3irdv6kd3rVH/PUjiCSIP5SvpCMvwJzDNg==",
-			"cpu": [
-				"arm"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"linux"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-linux-arm64-gnu": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.2.93.tgz",
-			"integrity": "sha512-UdQX3Tt7xLUgC4AFROw9wRaRA2vDHNnNFURkV//i/nsGay12JANBvXA/FOMge6yx32tPvcNUSRHnb3MYep0kzg==",
-			"cpu": [
-				"arm64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"linux"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-linux-arm64-musl": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.2.93.tgz",
-			"integrity": "sha512-O5W/cjnkP9nuKZsx03/DxVO+ILh5BUmfCjFzScXGuLMIZrBLyzBstcaSaZOxfd04wPEqael4VZiAGmWXornZ1g==",
-			"cpu": [
-				"arm64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"linux"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-linux-x64-gnu": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.2.93.tgz",
-			"integrity": "sha512-fDELNkklMzEI8KDr51XGajP7TVbZCLYkiPGAgbGadmkMFvlgJfzf1Qt1VzjGk5lTYdQO40vCe7u4xEpfdq6lLQ==",
-			"cpu": [
-				"x64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"linux"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-linux-x64-musl": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.2.93.tgz",
-			"integrity": "sha512-ZdEi04dfj96XDjT+J2k/J/m3WoHqlfwz93dTlpWdlPvrSNtsMg2oorm0Zynx/x2Ghe3w1hJu3HdMaJF2UY3Ttw==",
-			"cpu": [
-				"x64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"linux"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-win32-arm64-msvc": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.2.93.tgz",
-			"integrity": "sha512-NbIyBpOCEqxa+s3x8ijQGBOxQd5P63icf+6SK6MkO5E2zTgiR4g6ziihKCdhF9tJ6M4c0DHL/RqIV5SS9UX01w==",
-			"cpu": [
-				"arm64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"win32"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-win32-ia32-msvc": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.2.93.tgz",
-			"integrity": "sha512-TrRfHzGBQL1fjTahfBLDYcjLx28tH7pN5co5fJmYgASey8McVWL6eW/q/9fxvZqOVyj2SF9wvLDYKm0IWz4f+g==",
-			"cpu": [
-				"ia32"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"win32"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
-		"node_modules/@swc/core-win32-x64-msvc": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.2.93.tgz",
-			"integrity": "sha512-VsqLVB7ytNYqEC21amMswC2c84NCVNW6KLhS9XeO6Vz1+7wx8uPu1rAo14oBu5/3yhv7/K3wgfMqJMKHZtXPMQ==",
-			"cpu": [
-				"x64"
-			],
-			"dev": true,
-			"optional": true,
-			"os": [
-				"win32"
-			],
-			"engines": {
-				"node": ">=10"
-			}
-		},
 		"node_modules/@tootallnate/once": {
 			"version": "1.1.2",
 			"resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz",
@@ -1320,6 +1025,30 @@
 				"node": ">= 6"
 			}
 		},
+		"node_modules/@tsconfig/node10": {
+			"version": "1.0.8",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.8.tgz",
+			"integrity": "sha512-6XFfSQmMgq0CFLY1MslA/CPUfhIL919M1rMsa5lP2P097N2Wd1sSX0tx1u4olM16fLNhtHZpRhedZJphNJqmZg==",
+			"dev": true
+		},
+		"node_modules/@tsconfig/node12": {
+			"version": "1.0.9",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.9.tgz",
+			"integrity": "sha512-/yBMcem+fbvhSREH+s14YJi18sp7J9jpuhYByADT2rypfajMZZN4WQ6zBGgBKp53NKmqI36wFYDb3yaMPurITw==",
+			"dev": true
+		},
+		"node_modules/@tsconfig/node14": {
+			"version": "1.0.1",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.1.tgz",
+			"integrity": "sha512-509r2+yARFfHHE7T6Puu2jjkoycftovhXRqW328PDXTVGKihlb1P8Z9mMZH04ebyajfRY7dedfGynlrFHJUQCg==",
+			"dev": true
+		},
+		"node_modules/@tsconfig/node16": {
+			"version": "1.0.2",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.2.tgz",
+			"integrity": "sha512-eZxlbI8GZscaGS7kkc/trHTT5xgrjH3/1n2JDwusC9iahPKWMRvRjJSAN5mCXviuTGQ/lHnhvv8Q1YTpnfz9gA==",
+			"dev": true
+		},
 		"node_modules/@types/amqplib": {
 			"version": "0.8.2",
 			"resolved": "https://registry.npmjs.org/@types/amqplib/-/amqplib-0.8.2.tgz",
@@ -1457,11 +1186,6 @@
 			"resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.9.tgz",
 			"integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ=="
 		},
-		"node_modules/@types/json5": {
-			"version": "0.0.29",
-			"resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz",
-			"integrity": "sha1-7ihweulOEdK4J7y+UnC86n8+ce4="
-		},
 		"node_modules/@types/jsonwebtoken": {
 			"version": "8.5.5",
 			"resolved": "https://registry.npmjs.org/@types/jsonwebtoken/-/jsonwebtoken-8.5.5.tgz",
@@ -1477,35 +1201,6 @@
 			"integrity": "sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw==",
 			"dev": true
 		},
-		"node_modules/@types/mongodb": {
-			"version": "4.0.7",
-			"resolved": "https://registry.npmjs.org/@types/mongodb/-/mongodb-4.0.7.tgz",
-			"integrity": "sha512-lPUYPpzA43baXqnd36cZ9xxorprybxXDzteVKCPAdp14ppHtFJHnXYvNpmBvtMUTb5fKXVv6sVbzo1LHkWhJlw==",
-			"deprecated": "mongodb provides its own types. @types/mongodb is no longer needed.",
-			"dev": true,
-			"dependencies": {
-				"mongodb": "*"
-			}
-		},
-		"node_modules/@types/mongoose": {
-			"version": "5.10.5",
-			"resolved": "https://registry.npmjs.org/@types/mongoose/-/mongoose-5.10.5.tgz",
-			"integrity": "sha512-37QMIA954T3n+HSksSNLlxZsqF8fMJu5S4dyPBod6gRxGtsXlQ9jUtL8BE8Seimv99u79eLXI3bggoCnSQ/fxQ==",
-			"dev": true,
-			"dependencies": {
-				"@types/mongodb": "*",
-				"@types/node": "*"
-			}
-		},
-		"node_modules/@types/mongoose-autopopulate": {
-			"version": "0.10.2",
-			"resolved": "https://registry.npmjs.org/@types/mongoose-autopopulate/-/mongoose-autopopulate-0.10.2.tgz",
-			"integrity": "sha512-YSxSEhszXK9E+7VRLdpYjkXqcRXOPFtG0xZea9n7A+oaHhZ1lSVBm/WvK2Rr746NPrTm/k1tR6uezyG6kyinyg==",
-			"dev": true,
-			"dependencies": {
-				"@types/mongoose": "5.10.5"
-			}
-		},
 		"node_modules/@types/multer": {
 			"version": "1.4.7",
 			"resolved": "https://registry.npmjs.org/@types/multer/-/multer-1.4.7.tgz",
@@ -1564,11 +1259,6 @@
 			"integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==",
 			"dev": true
 		},
-		"node_modules/@types/validator": {
-			"version": "13.6.3",
-			"resolved": "https://registry.npmjs.org/@types/validator/-/validator-13.6.3.tgz",
-			"integrity": "sha512-fWG42pMJOL4jKsDDZZREnXLjc3UE0R8LOJfARWYg6U966rxDT7TYejYzLnUF5cvSObGg34nd0+H2wHHU5Omdfw=="
-		},
 		"node_modules/@types/yargs": {
 			"version": "16.0.4",
 			"resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-16.0.4.tgz",
@@ -1695,21 +1385,6 @@
 			"integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
 			"dev": true
 		},
-		"node_modules/ajv": {
-			"version": "8.6.3",
-			"resolved": "https://registry.npmjs.org/ajv/-/ajv-8.6.3.tgz",
-			"integrity": "sha512-SMJOdDP6LqTkD0Uq8qLi+gMwSt0imXLSV080qFVwJCpH9U6Mb+SUGHAXM0KNbcBPguytWyvFxcHgMLe2D2XSpw==",
-			"dependencies": {
-				"fast-deep-equal": "^3.1.1",
-				"json-schema-traverse": "^1.0.0",
-				"require-from-string": "^2.0.2",
-				"uri-js": "^4.2.2"
-			},
-			"funding": {
-				"type": "github",
-				"url": "https://github.com/sponsors/epoberezkin"
-			}
-		},
 		"node_modules/amqplib": {
 			"version": "0.8.0",
 			"resolved": "https://registry.npmjs.org/amqplib/-/amqplib-0.8.0.tgz",
@@ -2045,7 +1720,8 @@
 			"version": "2.2.1",
 			"resolved": "https://registry.npmjs.org/bl/-/bl-2.2.1.tgz",
 			"integrity": "sha512-6Pesp1w0DEX1N550i/uGV/TqucVL4AM/pgThFSN/Qq9si1/DF9aIHs1BxD8V/QU0HoeHO6cQRTAuYnLPKq1e4g==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"readable-stream": "^2.3.5",
 				"safe-buffer": "^5.1.1"
@@ -2055,13 +1731,15 @@
 			"version": "1.0.0",
 			"resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
 			"integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=",
-			"devOptional": true
+			"optional": true,
+			"peer": true
 		},
 		"node_modules/bl/node_modules/readable-stream": {
 			"version": "2.3.7",
 			"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz",
 			"integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"core-util-is": "~1.0.0",
 				"inherits": "~2.0.3",
@@ -2076,13 +1754,15 @@
 			"version": "5.1.2",
 			"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
 			"integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",
-			"devOptional": true
+			"optional": true,
+			"peer": true
 		},
 		"node_modules/bl/node_modules/string_decoder": {
 			"version": "1.1.1",
 			"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
 			"integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"safe-buffer": "~5.1.0"
 			}
@@ -2186,7 +1866,8 @@
 			"version": "1.1.6",
 			"resolved": "https://registry.npmjs.org/bson/-/bson-1.1.6.tgz",
 			"integrity": "sha512-EvVNVeGo4tHxwi8L6bPj3y3itEvStdwvvlojVxxbyYfoaxJ6keLgrTuKdyfEAszFK+H3olzBuafE0yoh0D1gdg==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"engines": {
 				"node": ">=0.6.19"
 			}
@@ -2309,16 +1990,6 @@
 			"integrity": "sha512-cOU9usZw8/dXIXKtwa8pM0OTJQuJkxMN6w30csNRUerHfeQ5R6U3kkU/FtJeIf3M202OHfY2U8ccInBG7/xogA==",
 			"dev": true
 		},
-		"node_modules/class-validator": {
-			"version": "0.13.1",
-			"resolved": "https://registry.npmjs.org/class-validator/-/class-validator-0.13.1.tgz",
-			"integrity": "sha512-zWIeYFhUitvAHBwNhDdCRK09hWx+P0HUwFE8US8/CxFpMVzkUK8RJl7yOIE+BVu2lxyPNgeOaFv78tLE47jBIg==",
-			"dependencies": {
-				"@types/validator": "^13.1.3",
-				"libphonenumber-js": "^1.9.7",
-				"validator": "^13.5.2"
-			}
-		},
 		"node_modules/cli-highlight": {
 			"version": "2.1.11",
 			"resolved": "https://registry.npmjs.org/cli-highlight/-/cli-highlight-2.1.11.tgz",
@@ -2433,15 +2104,6 @@
 				"node": ">= 0.8"
 			}
 		},
-		"node_modules/commander": {
-			"version": "7.2.0",
-			"resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz",
-			"integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==",
-			"dev": true,
-			"engines": {
-				"node": ">= 10"
-			}
-		},
 		"node_modules/concat-map": {
 			"version": "0.0.1",
 			"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
@@ -2685,7 +2347,8 @@
 			"version": "1.5.1",
 			"resolved": "https://registry.npmjs.org/denque/-/denque-1.5.1.tgz",
 			"integrity": "sha512-XwE+iZ4D6ZUB7mfYRMb5wByE8L74HCn30FBN7sWnXksWc1LO1bPDl67pBR9o/kC4z/xSNAwkMYcGgqDV3BE3Hw==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"engines": {
 				"node": ">=0.10"
 			}
@@ -2773,20 +2436,6 @@
 				"node": ">=8"
 			}
 		},
-		"node_modules/dot-prop": {
-			"version": "6.0.1",
-			"resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-6.0.1.tgz",
-			"integrity": "sha512-tE7ztYzXHIeyvc7N+hR3oi7FIbf/NIjVP9hmAt3yMXzrQ072/fpjGLx2GxNxGxUl5V73MEqYzioOMoVhGMJ5cA==",
-			"dependencies": {
-				"is-obj": "^2.0.0"
-			},
-			"engines": {
-				"node": ">=10"
-			},
-			"funding": {
-				"url": "https://github.com/sponsors/sindresorhus"
-			}
-		},
 		"node_modules/dotenv": {
 			"version": "8.6.0",
 			"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.6.0.tgz",
@@ -2849,14 +2498,6 @@
 				"node": ">= 0.8"
 			}
 		},
-		"node_modules/env-paths": {
-			"version": "2.2.1",
-			"resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz",
-			"integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==",
-			"engines": {
-				"node": ">=6"
-			}
-		},
 		"node_modules/escalade": {
 			"version": "3.1.1",
 			"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@@ -3072,23 +2713,8 @@
 		"node_modules/fast-deep-equal": {
 			"version": "3.1.3",
 			"resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
-			"integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q=="
-		},
-		"node_modules/fast-glob": {
-			"version": "3.2.7",
-			"resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.7.tgz",
-			"integrity": "sha512-rYGMRwip6lUMvYD3BTScMwT1HtAs2d71SMv66Vrxs0IekGZEjhM0pcMfjQPnknBt2zeCwQMEupiN02ZP4DiT1Q==",
-			"dev": true,
-			"dependencies": {
-				"@nodelib/fs.stat": "^2.0.2",
-				"@nodelib/fs.walk": "^1.2.3",
-				"glob-parent": "^5.1.2",
-				"merge2": "^1.3.0",
-				"micromatch": "^4.0.4"
-			},
-			"engines": {
-				"node": ">=8"
-			}
+			"integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
+			"optional": true
 		},
 		"node_modules/fast-json-stable-stringify": {
 			"version": "2.1.0",
@@ -3102,15 +2728,6 @@
 			"integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=",
 			"dev": true
 		},
-		"node_modules/fastq": {
-			"version": "1.13.0",
-			"resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz",
-			"integrity": "sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw==",
-			"dev": true,
-			"dependencies": {
-				"reusify": "^1.0.4"
-			}
-		},
 		"node_modules/fb-watchman": {
 			"version": "2.0.1",
 			"resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.1.tgz",
@@ -3389,18 +3006,6 @@
 				"url": "https://github.com/sponsors/isaacs"
 			}
 		},
-		"node_modules/glob-parent": {
-			"version": "5.1.2",
-			"resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
-			"integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
-			"dev": true,
-			"dependencies": {
-				"is-glob": "^4.0.1"
-			},
-			"engines": {
-				"node": ">= 6"
-			}
-		},
 		"node_modules/globals": {
 			"version": "11.12.0",
 			"resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz",
@@ -3783,15 +3388,6 @@
 				"url": "https://github.com/sponsors/sindresorhus"
 			}
 		},
-		"node_modules/is-extglob": {
-			"version": "2.1.1",
-			"resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
-			"integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=",
-			"dev": true,
-			"engines": {
-				"node": ">=0.10.0"
-			}
-		},
 		"node_modules/is-fullwidth-code-point": {
 			"version": "1.0.0",
 			"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz",
@@ -3812,18 +3408,6 @@
 				"node": ">=6"
 			}
 		},
-		"node_modules/is-glob": {
-			"version": "4.0.3",
-			"resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
-			"integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
-			"dev": true,
-			"dependencies": {
-				"is-extglob": "^2.1.1"
-			},
-			"engines": {
-				"node": ">=0.10.0"
-			}
-		},
 		"node_modules/is-number": {
 			"version": "7.0.0",
 			"resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
@@ -3832,14 +3416,6 @@
 				"node": ">=0.12.0"
 			}
 		},
-		"node_modules/is-obj": {
-			"version": "2.0.0",
-			"resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz",
-			"integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w==",
-			"engines": {
-				"node": ">=8"
-			}
-		},
 		"node_modules/is-potential-custom-element-name": {
 			"version": "1.0.1",
 			"resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz",
@@ -4702,11 +4278,6 @@
 			"integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=",
 			"optional": true
 		},
-		"node_modules/json-schema-traverse": {
-			"version": "1.0.0",
-			"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
-			"integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug=="
-		},
 		"node_modules/json-stable-stringify": {
 			"version": "1.0.1",
 			"resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz",
@@ -4872,11 +4443,6 @@
 				"node": ">= 0.8.0"
 			}
 		},
-		"node_modules/libphonenumber-js": {
-			"version": "1.9.34",
-			"resolved": "https://registry.npmjs.org/libphonenumber-js/-/libphonenumber-js-1.9.34.tgz",
-			"integrity": "sha512-gHTNU9xTtVgSp30IDX/57W4pETMXDIYXFfwEOJVXiYosiY7Hc7ogJwlBjOqlCcU04X0aA8DT57hdwUC1sJBJnA=="
-		},
 		"node_modules/locate-path": {
 			"version": "5.0.0",
 			"resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz",
@@ -4983,8 +4549,8 @@
 			"version": "1.5.0",
 			"resolved": "https://registry.npmjs.org/memory-pager/-/memory-pager-1.5.0.tgz",
 			"integrity": "sha512-ZS4Bp4r/Zoeq6+NLJpP+0Zzm0pR8whtGPf1XExKLJBAczGMnSi3It14OiNCStjQjM6NU1okjQGSxgEZN8eBYKg==",
-			"dev": true,
-			"optional": true
+			"optional": true,
+			"peer": true
 		},
 		"node_modules/merge-descriptors": {
 			"version": "1.0.1",
@@ -4997,15 +4563,6 @@
 			"integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==",
 			"dev": true
 		},
-		"node_modules/merge2": {
-			"version": "1.4.1",
-			"resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz",
-			"integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==",
-			"dev": true,
-			"engines": {
-				"node": ">= 8"
-			}
-		},
 		"node_modules/methods": {
 			"version": "1.1.2",
 			"resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz",
@@ -5123,7 +4680,8 @@
 			"version": "3.7.1",
 			"resolved": "https://registry.npmjs.org/mongodb/-/mongodb-3.7.1.tgz",
 			"integrity": "sha512-iSVgexYr8ID0ieeNFUbRfQeOZxOchRck6kEDVySQRaa8VIw/1Pm+/LgcpZcl/BWV6nT0L8lP9qyl7dRPJ6mnLw==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"bl": "^2.2.1",
 				"bson": "^1.1.4",
@@ -5562,7 +5120,8 @@
 			"version": "1.1.7",
 			"resolved": "https://registry.npmjs.org/optional-require/-/optional-require-1.1.7.tgz",
 			"integrity": "sha512-cIeRZocXsZnZYn+SevbtSqNlLbeoS4mLzuNn4fvXRMDRNhTGg0sxuKXl0FnZCtnew85LorNxIbZp5OeliILhMw==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"require-at": "^1.0.6"
 			},
@@ -6143,6 +5702,7 @@
 			"version": "2.1.1",
 			"resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
 			"integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==",
+			"devOptional": true,
 			"engines": {
 				"node": ">=6"
 			}
@@ -6160,26 +5720,6 @@
 			"resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz",
 			"integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ=="
 		},
-		"node_modules/queue-microtask": {
-			"version": "1.2.3",
-			"resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
-			"integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==",
-			"dev": true,
-			"funding": [
-				{
-					"type": "github",
-					"url": "https://github.com/sponsors/feross"
-				},
-				{
-					"type": "patreon",
-					"url": "https://www.patreon.com/feross"
-				},
-				{
-					"type": "consulting",
-					"url": "https://feross.org/support"
-				}
-			]
-		},
 		"node_modules/range-parser": {
 			"version": "1.2.1",
 			"resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz",
@@ -6310,7 +5850,8 @@
 			"version": "1.0.6",
 			"resolved": "https://registry.npmjs.org/require-at/-/require-at-1.0.6.tgz",
 			"integrity": "sha512-7i1auJbMUrXEAZCOQ0VNJgmcT2VOKPRl2YGJwgpHpC9CE91Mv4/4UYIUm4chGJaI381ZDq1JUicFii64Hapd8g==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"engines": {
 				"node": ">=4"
 			}
@@ -6323,14 +5864,6 @@
 				"node": ">=0.10.0"
 			}
 		},
-		"node_modules/require-from-string": {
-			"version": "2.0.2",
-			"resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz",
-			"integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==",
-			"engines": {
-				"node": ">=0.10.0"
-			}
-		},
 		"node_modules/requires-port": {
 			"version": "1.0.0",
 			"resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz",
@@ -6370,16 +5903,6 @@
 				"node": ">=8"
 			}
 		},
-		"node_modules/reusify": {
-			"version": "1.0.4",
-			"resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz",
-			"integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==",
-			"dev": true,
-			"engines": {
-				"iojs": ">=1.0.0",
-				"node": ">=0.10.0"
-			}
-		},
 		"node_modules/rimraf": {
 			"version": "3.0.2",
 			"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
@@ -6395,29 +5918,6 @@
 				"url": "https://github.com/sponsors/isaacs"
 			}
 		},
-		"node_modules/run-parallel": {
-			"version": "1.2.0",
-			"resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
-			"integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
-			"dev": true,
-			"funding": [
-				{
-					"type": "github",
-					"url": "https://github.com/sponsors/feross"
-				},
-				{
-					"type": "patreon",
-					"url": "https://www.patreon.com/feross"
-				},
-				{
-					"type": "consulting",
-					"url": "https://feross.org/support"
-				}
-			],
-			"dependencies": {
-				"queue-microtask": "^1.2.2"
-			}
-		},
 		"node_modules/safe-buffer": {
 			"version": "5.2.1",
 			"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
@@ -6446,8 +5946,8 @@
 			"version": "1.0.3",
 			"resolved": "https://registry.npmjs.org/saslprep/-/saslprep-1.0.3.tgz",
 			"integrity": "sha512-/MY/PEMbk2SuY5sScONwhUDsV2p77Znkb/q3nSVstq/yQzYJOH/Azh29p9oJLsl3LnQwSvZDKagDGBsBwSooag==",
-			"dev": true,
 			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"sparse-bitfield": "^3.0.3"
 			},
@@ -6607,8 +6107,8 @@
 			"version": "3.0.3",
 			"resolved": "https://registry.npmjs.org/sparse-bitfield/-/sparse-bitfield-3.0.3.tgz",
 			"integrity": "sha1-/0rm5oZWBWuks+eSqzM004JzyhE=",
-			"dev": true,
 			"optional": true,
+			"peer": true,
 			"dependencies": {
 				"memory-pager": "^1.0.2"
 			}
@@ -6977,34 +6477,57 @@
 				"node": ">=8"
 			}
 		},
-		"node_modules/tsconfig-paths": {
-			"version": "3.11.0",
-			"resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.11.0.tgz",
-			"integrity": "sha512-7ecdYDnIdmv639mmDwslG6KQg1Z9STTz1j7Gcz0xa+nshh/gKDAHcPxRbWOsA3SPp0tXP2leTcY9Kw+NAkfZzA==",
-			"dependencies": {
-				"@types/json5": "^0.0.29",
-				"json5": "^1.0.1",
-				"minimist": "^1.2.0",
-				"strip-bom": "^3.0.0"
-			}
-		},
-		"node_modules/tsconfig-paths/node_modules/json5": {
-			"version": "1.0.1",
-			"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz",
-			"integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==",
+		"node_modules/ts-node": {
+			"version": "10.2.1",
+			"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.2.1.tgz",
+			"integrity": "sha512-hCnyOyuGmD5wHleOQX6NIjJtYVIO8bPP8F2acWkB4W06wdlkgyvJtubO/I9NkI88hCFECbsEgoLc0VNkYmcSfw==",
+			"dev": true,
 			"dependencies": {
-				"minimist": "^1.2.0"
+				"@cspotcode/source-map-support": "0.6.1",
+				"@tsconfig/node10": "^1.0.7",
+				"@tsconfig/node12": "^1.0.7",
+				"@tsconfig/node14": "^1.0.0",
+				"@tsconfig/node16": "^1.0.2",
+				"acorn": "^8.4.1",
+				"acorn-walk": "^8.1.1",
+				"arg": "^4.1.0",
+				"create-require": "^1.1.0",
+				"diff": "^4.0.1",
+				"make-error": "^1.1.1",
+				"yn": "3.1.1"
 			},
 			"bin": {
-				"json5": "lib/cli.js"
+				"ts-node": "dist/bin.js",
+				"ts-node-cwd": "dist/bin-cwd.js",
+				"ts-node-script": "dist/bin-script.js",
+				"ts-node-transpile-only": "dist/bin-transpile.js",
+				"ts-script": "dist/bin-script-deprecated.js"
+			},
+			"engines": {
+				"node": ">=12.0.0"
+			},
+			"peerDependencies": {
+				"@swc/core": ">=1.2.50",
+				"@swc/wasm": ">=1.2.50",
+				"@types/node": "*",
+				"typescript": ">=2.7"
+			},
+			"peerDependenciesMeta": {
+				"@swc/core": {
+					"optional": true
+				},
+				"@swc/wasm": {
+					"optional": true
+				}
 			}
 		},
-		"node_modules/tsconfig-paths/node_modules/strip-bom": {
-			"version": "3.0.0",
-			"resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz",
-			"integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=",
+		"node_modules/ts-node/node_modules/acorn-walk": {
+			"version": "8.2.0",
+			"resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
+			"integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==",
+			"dev": true,
 			"engines": {
-				"node": ">=4"
+				"node": ">=0.4.0"
 			}
 		},
 		"node_modules/tslib": {
@@ -7378,6 +6901,7 @@
 			"version": "4.4.1",
 			"resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
 			"integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
+			"optional": true,
 			"dependencies": {
 				"punycode": "^2.1.0"
 			}
@@ -7437,14 +6961,6 @@
 				"node": ">= 8"
 			}
 		},
-		"node_modules/validator": {
-			"version": "13.6.0",
-			"resolved": "https://registry.npmjs.org/validator/-/validator-13.6.0.tgz",
-			"integrity": "sha512-gVgKbdbHgtxpRyR8K0O6oFZPhhB5tT1jeEHZR0Znr9Svg03U0+r9DXWMrnRAB+HtCStDQKlaIZm42tVsVjqtjg==",
-			"engines": {
-				"node": ">= 0.10"
-			}
-		},
 		"node_modules/vary": {
 			"version": "1.1.2",
 			"resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz",
@@ -8316,6 +7832,21 @@
 			"integrity": "sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw==",
 			"dev": true
 		},
+		"@cspotcode/source-map-consumer": {
+			"version": "0.8.0",
+			"resolved": "https://registry.npmjs.org/@cspotcode/source-map-consumer/-/source-map-consumer-0.8.0.tgz",
+			"integrity": "sha512-41qniHzTU8yAGbCp04ohlmSrZf8bkf/iJsl3V0dRGsQN/5GFfx+LbCSsCpp2gqrqjTVg/K6O8ycoV35JIwAzAg==",
+			"dev": true
+		},
+		"@cspotcode/source-map-support": {
+			"version": "0.6.1",
+			"resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.6.1.tgz",
+			"integrity": "sha512-DX3Z+T5dt1ockmPdobJS/FAsQPW4V4SrWEhD2iYQT2Cb2tQsiMnYxrcUH9By/Z3B+v0S5LMBkQtV/XOBbpLEOg==",
+			"dev": true,
+			"requires": {
+				"@cspotcode/source-map-consumer": "0.8.0"
+			}
+		},
 		"@istanbuljs/load-nyc-config": {
 			"version": "1.1.0",
 			"resolved": "https://registry.npmjs.org/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz",
@@ -8557,47 +8088,6 @@
 				"chalk": "^4.0.0"
 			}
 		},
-		"@napi-rs/triples": {
-			"version": "1.0.3",
-			"resolved": "https://registry.npmjs.org/@napi-rs/triples/-/triples-1.0.3.tgz",
-			"integrity": "sha512-jDJTpta+P4p1NZTFVLHJ/TLFVYVcOqv6l8xwOeBKNPMgY/zDYH/YH7SJbvrr/h1RcS9GzbPcLKGzpuK9cV56UA==",
-			"dev": true
-		},
-		"@node-rs/helper": {
-			"version": "1.2.1",
-			"resolved": "https://registry.npmjs.org/@node-rs/helper/-/helper-1.2.1.tgz",
-			"integrity": "sha512-R5wEmm8nbuQU0YGGmYVjEc0OHtYsuXdpRG+Ut/3wZ9XAvQWyThN08bTh2cBJgoZxHQUPtvRfeQuxcAgLuiBISg==",
-			"dev": true,
-			"requires": {
-				"@napi-rs/triples": "^1.0.3"
-			}
-		},
-		"@nodelib/fs.scandir": {
-			"version": "2.1.5",
-			"resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz",
-			"integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==",
-			"dev": true,
-			"requires": {
-				"@nodelib/fs.stat": "2.0.5",
-				"run-parallel": "^1.1.9"
-			}
-		},
-		"@nodelib/fs.stat": {
-			"version": "2.0.5",
-			"resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz",
-			"integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==",
-			"dev": true
-		},
-		"@nodelib/fs.walk": {
-			"version": "1.2.8",
-			"resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz",
-			"integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==",
-			"dev": true,
-			"requires": {
-				"@nodelib/fs.scandir": "2.1.5",
-				"fastq": "^1.6.0"
-			}
-		},
 		"@sinonjs/commons": {
 			"version": "1.8.3",
 			"resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-1.8.3.tgz",
@@ -8621,137 +8111,36 @@
 			"resolved": "https://registry.npmjs.org/@sqltools/formatter/-/formatter-1.2.3.tgz",
 			"integrity": "sha512-O3uyB/JbkAEMZaP3YqyHH7TMnex7tWyCbCI4EfJdOCoN6HIhqdJBWTM6aCCiWQ/5f5wxjgU735QAIpJbjDvmzg=="
 		},
-		"@swc/cli": {
-			"version": "0.1.51",
-			"resolved": "https://registry.npmjs.org/@swc/cli/-/cli-0.1.51.tgz",
-			"integrity": "sha512-7eqZGpkI4QOYfF+9FV4xpT/V/LSRDs5OMJcm4Z46JnPMvv+sxumAFdCe1hHRzHgnzwis9OtjI8Tt3Srf9JudQw==",
-			"dev": true,
-			"requires": {
-				"commander": "^7.1.0",
-				"fast-glob": "^3.2.5",
-				"slash": "3.0.0",
-				"source-map": "^0.7.3"
-			},
-			"dependencies": {
-				"source-map": {
-					"version": "0.7.3",
-					"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.7.3.tgz",
-					"integrity": "sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ==",
-					"dev": true
-				}
-			}
-		},
-		"@swc/core": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core/-/core-1.2.93.tgz",
-			"integrity": "sha512-Lx9I+9GfUl2Mb7r23MVbSkc+NZE0+xZ4Xh787D1b82KMeFLz7QgYe4cNM9SzTjV/VlSQyNTVlzjES7ZThIUvtA==",
-			"dev": true,
-			"requires": {
-				"@node-rs/helper": "^1.0.0",
-				"@swc/core-android-arm64": "1.2.93",
-				"@swc/core-darwin-arm64": "1.2.93",
-				"@swc/core-darwin-x64": "1.2.93",
-				"@swc/core-freebsd-x64": "1.2.93",
-				"@swc/core-linux-arm-gnueabihf": "1.2.93",
-				"@swc/core-linux-arm64-gnu": "1.2.93",
-				"@swc/core-linux-arm64-musl": "1.2.93",
-				"@swc/core-linux-x64-gnu": "1.2.93",
-				"@swc/core-linux-x64-musl": "1.2.93",
-				"@swc/core-win32-arm64-msvc": "1.2.93",
-				"@swc/core-win32-ia32-msvc": "1.2.93",
-				"@swc/core-win32-x64-msvc": "1.2.93"
-			}
-		},
-		"@swc/core-android-arm64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-android-arm64/-/core-android-arm64-1.2.93.tgz",
-			"integrity": "sha512-3F5A7QNR5+MI64W20QBADU0Z6knt8kJOxIoKw4Vuk7JQ6k0nnMemio3LtusHgAVZLXq0wMILZ4kv/+qnRzWb7A==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-darwin-arm64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-darwin-arm64/-/core-darwin-arm64-1.2.93.tgz",
-			"integrity": "sha512-a8tu9WCtnjiuKTscUu8N9z/vVuIldwo5US4WfYi2dtQNgf21n1ZKxwvsZzRz6mEC86zVE0k9pmslwEtMuuCJog==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-darwin-x64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-darwin-x64/-/core-darwin-x64-1.2.93.tgz",
-			"integrity": "sha512-ga8bpjauZYHWMjuPKcqOZFSgStvveMc/J7yqIlr9sF2pOr7Rt/MKLO4Ups95A2Aay90aCF9cPKQDtX71PmdlVw==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-freebsd-x64": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-freebsd-x64/-/core-freebsd-x64-1.2.93.tgz",
-			"integrity": "sha512-qDBEZqHh6C2AMaxjdm/Am8MUwN94RS3na9VLYDMGUkgs2yvnSADfx7JOyZEJT1Ot7FZEuyGXcSfomUzNCU/5kw==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-linux-arm-gnueabihf": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-arm-gnueabihf/-/core-linux-arm-gnueabihf-1.2.93.tgz",
-			"integrity": "sha512-KlJsXOcZpuHXU8hMVDXfSyBQ9fdUpzwDV1JKpfIehG+P2kRdCbiN3irdv6kd3rVH/PUjiCSIP5SvpCMvwJzDNg==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-linux-arm64-gnu": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-arm64-gnu/-/core-linux-arm64-gnu-1.2.93.tgz",
-			"integrity": "sha512-UdQX3Tt7xLUgC4AFROw9wRaRA2vDHNnNFURkV//i/nsGay12JANBvXA/FOMge6yx32tPvcNUSRHnb3MYep0kzg==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-linux-arm64-musl": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-arm64-musl/-/core-linux-arm64-musl-1.2.93.tgz",
-			"integrity": "sha512-O5W/cjnkP9nuKZsx03/DxVO+ILh5BUmfCjFzScXGuLMIZrBLyzBstcaSaZOxfd04wPEqael4VZiAGmWXornZ1g==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-linux-x64-gnu": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-x64-gnu/-/core-linux-x64-gnu-1.2.93.tgz",
-			"integrity": "sha512-fDELNkklMzEI8KDr51XGajP7TVbZCLYkiPGAgbGadmkMFvlgJfzf1Qt1VzjGk5lTYdQO40vCe7u4xEpfdq6lLQ==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-linux-x64-musl": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-linux-x64-musl/-/core-linux-x64-musl-1.2.93.tgz",
-			"integrity": "sha512-ZdEi04dfj96XDjT+J2k/J/m3WoHqlfwz93dTlpWdlPvrSNtsMg2oorm0Zynx/x2Ghe3w1hJu3HdMaJF2UY3Ttw==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-win32-arm64-msvc": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-win32-arm64-msvc/-/core-win32-arm64-msvc-1.2.93.tgz",
-			"integrity": "sha512-NbIyBpOCEqxa+s3x8ijQGBOxQd5P63icf+6SK6MkO5E2zTgiR4g6ziihKCdhF9tJ6M4c0DHL/RqIV5SS9UX01w==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-win32-ia32-msvc": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-win32-ia32-msvc/-/core-win32-ia32-msvc-1.2.93.tgz",
-			"integrity": "sha512-TrRfHzGBQL1fjTahfBLDYcjLx28tH7pN5co5fJmYgASey8McVWL6eW/q/9fxvZqOVyj2SF9wvLDYKm0IWz4f+g==",
-			"dev": true,
-			"optional": true
-		},
-		"@swc/core-win32-x64-msvc": {
-			"version": "1.2.93",
-			"resolved": "https://registry.npmjs.org/@swc/core-win32-x64-msvc/-/core-win32-x64-msvc-1.2.93.tgz",
-			"integrity": "sha512-VsqLVB7ytNYqEC21amMswC2c84NCVNW6KLhS9XeO6Vz1+7wx8uPu1rAo14oBu5/3yhv7/K3wgfMqJMKHZtXPMQ==",
-			"dev": true,
-			"optional": true
-		},
 		"@tootallnate/once": {
 			"version": "1.1.2",
 			"resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz",
 			"integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==",
 			"dev": true
 		},
+		"@tsconfig/node10": {
+			"version": "1.0.8",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.8.tgz",
+			"integrity": "sha512-6XFfSQmMgq0CFLY1MslA/CPUfhIL919M1rMsa5lP2P097N2Wd1sSX0tx1u4olM16fLNhtHZpRhedZJphNJqmZg==",
+			"dev": true
+		},
+		"@tsconfig/node12": {
+			"version": "1.0.9",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.9.tgz",
+			"integrity": "sha512-/yBMcem+fbvhSREH+s14YJi18sp7J9jpuhYByADT2rypfajMZZN4WQ6zBGgBKp53NKmqI36wFYDb3yaMPurITw==",
+			"dev": true
+		},
+		"@tsconfig/node14": {
+			"version": "1.0.1",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.1.tgz",
+			"integrity": "sha512-509r2+yARFfHHE7T6Puu2jjkoycftovhXRqW328PDXTVGKihlb1P8Z9mMZH04ebyajfRY7dedfGynlrFHJUQCg==",
+			"dev": true
+		},
+		"@tsconfig/node16": {
+			"version": "1.0.2",
+			"resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.2.tgz",
+			"integrity": "sha512-eZxlbI8GZscaGS7kkc/trHTT5xgrjH3/1n2JDwusC9iahPKWMRvRjJSAN5mCXviuTGQ/lHnhvv8Q1YTpnfz9gA==",
+			"dev": true
+		},
 		"@types/amqplib": {
 			"version": "0.8.2",
 			"resolved": "https://registry.npmjs.org/@types/amqplib/-/amqplib-0.8.2.tgz",
@@ -8889,11 +8278,6 @@
 			"resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.9.tgz",
 			"integrity": "sha512-qcUXuemtEu+E5wZSJHNxUXeCZhAfXKQ41D+duX+VYPde7xyEVZci+/oXKJL13tnRs9lR2pr4fod59GT6/X1/yQ=="
 		},
-		"@types/json5": {
-			"version": "0.0.29",
-			"resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz",
-			"integrity": "sha1-7ihweulOEdK4J7y+UnC86n8+ce4="
-		},
 		"@types/jsonwebtoken": {
 			"version": "8.5.5",
 			"resolved": "https://registry.npmjs.org/@types/jsonwebtoken/-/jsonwebtoken-8.5.5.tgz",
@@ -8909,34 +8293,6 @@
 			"integrity": "sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw==",
 			"dev": true
 		},
-		"@types/mongodb": {
-			"version": "4.0.7",
-			"resolved": "https://registry.npmjs.org/@types/mongodb/-/mongodb-4.0.7.tgz",
-			"integrity": "sha512-lPUYPpzA43baXqnd36cZ9xxorprybxXDzteVKCPAdp14ppHtFJHnXYvNpmBvtMUTb5fKXVv6sVbzo1LHkWhJlw==",
-			"dev": true,
-			"requires": {
-				"mongodb": "*"
-			}
-		},
-		"@types/mongoose": {
-			"version": "5.10.5",
-			"resolved": "https://registry.npmjs.org/@types/mongoose/-/mongoose-5.10.5.tgz",
-			"integrity": "sha512-37QMIA954T3n+HSksSNLlxZsqF8fMJu5S4dyPBod6gRxGtsXlQ9jUtL8BE8Seimv99u79eLXI3bggoCnSQ/fxQ==",
-			"dev": true,
-			"requires": {
-				"@types/mongodb": "*",
-				"@types/node": "*"
-			}
-		},
-		"@types/mongoose-autopopulate": {
-			"version": "0.10.2",
-			"resolved": "https://registry.npmjs.org/@types/mongoose-autopopulate/-/mongoose-autopopulate-0.10.2.tgz",
-			"integrity": "sha512-YSxSEhszXK9E+7VRLdpYjkXqcRXOPFtG0xZea9n7A+oaHhZ1lSVBm/WvK2Rr746NPrTm/k1tR6uezyG6kyinyg==",
-			"dev": true,
-			"requires": {
-				"@types/mongoose": "5.10.5"
-			}
-		},
 		"@types/multer": {
 			"version": "1.4.7",
 			"resolved": "https://registry.npmjs.org/@types/multer/-/multer-1.4.7.tgz",
@@ -8995,11 +8351,6 @@
 			"integrity": "sha512-Hl219/BT5fLAaz6NDkSuhzasy49dwQS/DSdu4MdggFB8zcXv7vflBI3xp7FEmkmdDkBUI2bPUNeMttp2knYdxw==",
 			"dev": true
 		},
-		"@types/validator": {
-			"version": "13.6.3",
-			"resolved": "https://registry.npmjs.org/@types/validator/-/validator-13.6.3.tgz",
-			"integrity": "sha512-fWG42pMJOL4jKsDDZZREnXLjc3UE0R8LOJfARWYg6U966rxDT7TYejYzLnUF5cvSObGg34nd0+H2wHHU5Omdfw=="
-		},
 		"@types/yargs": {
 			"version": "16.0.4",
 			"resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-16.0.4.tgz",
@@ -9101,17 +8452,6 @@
 				}
 			}
 		},
-		"ajv": {
-			"version": "8.6.3",
-			"resolved": "https://registry.npmjs.org/ajv/-/ajv-8.6.3.tgz",
-			"integrity": "sha512-SMJOdDP6LqTkD0Uq8qLi+gMwSt0imXLSV080qFVwJCpH9U6Mb+SUGHAXM0KNbcBPguytWyvFxcHgMLe2D2XSpw==",
-			"requires": {
-				"fast-deep-equal": "^3.1.1",
-				"json-schema-traverse": "^1.0.0",
-				"require-from-string": "^2.0.2",
-				"uri-js": "^4.2.2"
-			}
-		},
 		"amqplib": {
 			"version": "0.8.0",
 			"resolved": "https://registry.npmjs.org/amqplib/-/amqplib-0.8.0.tgz",
@@ -9383,7 +8723,8 @@
 			"version": "2.2.1",
 			"resolved": "https://registry.npmjs.org/bl/-/bl-2.2.1.tgz",
 			"integrity": "sha512-6Pesp1w0DEX1N550i/uGV/TqucVL4AM/pgThFSN/Qq9si1/DF9aIHs1BxD8V/QU0HoeHO6cQRTAuYnLPKq1e4g==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"requires": {
 				"readable-stream": "^2.3.5",
 				"safe-buffer": "^5.1.1"
@@ -9393,13 +8734,15 @@
 					"version": "1.0.0",
 					"resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
 					"integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=",
-					"devOptional": true
+					"optional": true,
+					"peer": true
 				},
 				"readable-stream": {
 					"version": "2.3.7",
 					"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz",
 					"integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==",
-					"devOptional": true,
+					"optional": true,
+					"peer": true,
 					"requires": {
 						"core-util-is": "~1.0.0",
 						"inherits": "~2.0.3",
@@ -9414,13 +8757,15 @@
 					"version": "5.1.2",
 					"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
 					"integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==",
-					"devOptional": true
+					"optional": true,
+					"peer": true
 				},
 				"string_decoder": {
 					"version": "1.1.1",
 					"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz",
 					"integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==",
-					"devOptional": true,
+					"optional": true,
+					"peer": true,
 					"requires": {
 						"safe-buffer": "~5.1.0"
 					}
@@ -9507,7 +8852,8 @@
 			"version": "1.1.6",
 			"resolved": "https://registry.npmjs.org/bson/-/bson-1.1.6.tgz",
 			"integrity": "sha512-EvVNVeGo4tHxwi8L6bPj3y3itEvStdwvvlojVxxbyYfoaxJ6keLgrTuKdyfEAszFK+H3olzBuafE0yoh0D1gdg==",
-			"devOptional": true
+			"optional": true,
+			"peer": true
 		},
 		"buffer-equal-constant-time": {
 			"version": "1.0.1",
@@ -9599,16 +8945,6 @@
 			"integrity": "sha512-cOU9usZw8/dXIXKtwa8pM0OTJQuJkxMN6w30csNRUerHfeQ5R6U3kkU/FtJeIf3M202OHfY2U8ccInBG7/xogA==",
 			"dev": true
 		},
-		"class-validator": {
-			"version": "0.13.1",
-			"resolved": "https://registry.npmjs.org/class-validator/-/class-validator-0.13.1.tgz",
-			"integrity": "sha512-zWIeYFhUitvAHBwNhDdCRK09hWx+P0HUwFE8US8/CxFpMVzkUK8RJl7yOIE+BVu2lxyPNgeOaFv78tLE47jBIg==",
-			"requires": {
-				"@types/validator": "^13.1.3",
-				"libphonenumber-js": "^1.9.7",
-				"validator": "^13.5.2"
-			}
-		},
 		"cli-highlight": {
 			"version": "2.1.11",
 			"resolved": "https://registry.npmjs.org/cli-highlight/-/cli-highlight-2.1.11.tgz",
@@ -9701,12 +9037,6 @@
 				"delayed-stream": "~1.0.0"
 			}
 		},
-		"commander": {
-			"version": "7.2.0",
-			"resolved": "https://registry.npmjs.org/commander/-/commander-7.2.0.tgz",
-			"integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==",
-			"dev": true
-		},
 		"concat-map": {
 			"version": "0.0.1",
 			"resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
@@ -9925,7 +9255,8 @@
 			"version": "1.5.1",
 			"resolved": "https://registry.npmjs.org/denque/-/denque-1.5.1.tgz",
 			"integrity": "sha512-XwE+iZ4D6ZUB7mfYRMb5wByE8L74HCn30FBN7sWnXksWc1LO1bPDl67pBR9o/kC4z/xSNAwkMYcGgqDV3BE3Hw==",
-			"devOptional": true
+			"optional": true,
+			"peer": true
 		},
 		"depd": {
 			"version": "1.1.2",
@@ -9985,14 +9316,6 @@
 				}
 			}
 		},
-		"dot-prop": {
-			"version": "6.0.1",
-			"resolved": "https://registry.npmjs.org/dot-prop/-/dot-prop-6.0.1.tgz",
-			"integrity": "sha512-tE7ztYzXHIeyvc7N+hR3oi7FIbf/NIjVP9hmAt3yMXzrQ072/fpjGLx2GxNxGxUl5V73MEqYzioOMoVhGMJ5cA==",
-			"requires": {
-				"is-obj": "^2.0.0"
-			}
-		},
 		"dotenv": {
 			"version": "8.6.0",
 			"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-8.6.0.tgz",
@@ -10043,11 +9366,6 @@
 			"resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz",
 			"integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k="
 		},
-		"env-paths": {
-			"version": "2.2.1",
-			"resolved": "https://registry.npmjs.org/env-paths/-/env-paths-2.2.1.tgz",
-			"integrity": "sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A=="
-		},
 		"escalade": {
 			"version": "3.1.1",
 			"resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz",
@@ -10210,20 +9528,8 @@
 		"fast-deep-equal": {
 			"version": "3.1.3",
 			"resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
-			"integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q=="
-		},
-		"fast-glob": {
-			"version": "3.2.7",
-			"resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.2.7.tgz",
-			"integrity": "sha512-rYGMRwip6lUMvYD3BTScMwT1HtAs2d71SMv66Vrxs0IekGZEjhM0pcMfjQPnknBt2zeCwQMEupiN02ZP4DiT1Q==",
-			"dev": true,
-			"requires": {
-				"@nodelib/fs.stat": "^2.0.2",
-				"@nodelib/fs.walk": "^1.2.3",
-				"glob-parent": "^5.1.2",
-				"merge2": "^1.3.0",
-				"micromatch": "^4.0.4"
-			}
+			"integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==",
+			"optional": true
 		},
 		"fast-json-stable-stringify": {
 			"version": "2.1.0",
@@ -10237,15 +9543,6 @@
 			"integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=",
 			"dev": true
 		},
-		"fastq": {
-			"version": "1.13.0",
-			"resolved": "https://registry.npmjs.org/fastq/-/fastq-1.13.0.tgz",
-			"integrity": "sha512-YpkpUnK8od0o1hmeSc7UUs/eB/vIPWJYjKck2QKIzAf71Vm1AAQ3EbuZB3g2JIy+pg+ERD0vqI79KyZiB2e2Nw==",
-			"dev": true,
-			"requires": {
-				"reusify": "^1.0.4"
-			}
-		},
 		"fb-watchman": {
 			"version": "2.0.1",
 			"resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.1.tgz",
@@ -10461,15 +9758,6 @@
 				"path-is-absolute": "^1.0.0"
 			}
 		},
-		"glob-parent": {
-			"version": "5.1.2",
-			"resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz",
-			"integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==",
-			"dev": true,
-			"requires": {
-				"is-glob": "^4.0.1"
-			}
-		},
 		"globals": {
 			"version": "11.12.0",
 			"resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz",
@@ -10751,12 +10039,6 @@
 			"resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz",
 			"integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ=="
 		},
-		"is-extglob": {
-			"version": "2.1.1",
-			"resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz",
-			"integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=",
-			"dev": true
-		},
 		"is-fullwidth-code-point": {
 			"version": "1.0.0",
 			"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz",
@@ -10771,25 +10053,11 @@
 			"integrity": "sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==",
 			"dev": true
 		},
-		"is-glob": {
-			"version": "4.0.3",
-			"resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz",
-			"integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==",
-			"dev": true,
-			"requires": {
-				"is-extglob": "^2.1.1"
-			}
-		},
 		"is-number": {
 			"version": "7.0.0",
 			"resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz",
 			"integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng=="
 		},
-		"is-obj": {
-			"version": "2.0.0",
-			"resolved": "https://registry.npmjs.org/is-obj/-/is-obj-2.0.0.tgz",
-			"integrity": "sha512-drqDG3cbczxxEJRoOXcOjtdp1J/lyp1mNn0xaznRs8+muBhgQcrnbspox5X5fOw0HnMnbfDzvnEMEtqDEJEo8w=="
-		},
 		"is-potential-custom-element-name": {
 			"version": "1.0.1",
 			"resolved": "https://registry.npmjs.org/is-potential-custom-element-name/-/is-potential-custom-element-name-1.0.1.tgz",
@@ -11466,11 +10734,6 @@
 			"integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=",
 			"optional": true
 		},
-		"json-schema-traverse": {
-			"version": "1.0.0",
-			"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz",
-			"integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug=="
-		},
 		"json-stable-stringify": {
 			"version": "1.0.1",
 			"resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz",
@@ -11610,11 +10873,6 @@
 				"type-check": "~0.3.2"
 			}
 		},
-		"libphonenumber-js": {
-			"version": "1.9.34",
-			"resolved": "https://registry.npmjs.org/libphonenumber-js/-/libphonenumber-js-1.9.34.tgz",
-			"integrity": "sha512-gHTNU9xTtVgSp30IDX/57W4pETMXDIYXFfwEOJVXiYosiY7Hc7ogJwlBjOqlCcU04X0aA8DT57hdwUC1sJBJnA=="
-		},
 		"locate-path": {
 			"version": "5.0.0",
 			"resolved": "https://registry.npmjs.org/locate-path/-/locate-path-5.0.0.tgz",
@@ -11706,8 +10964,8 @@
 			"version": "1.5.0",
 			"resolved": "https://registry.npmjs.org/memory-pager/-/memory-pager-1.5.0.tgz",
 			"integrity": "sha512-ZS4Bp4r/Zoeq6+NLJpP+0Zzm0pR8whtGPf1XExKLJBAczGMnSi3It14OiNCStjQjM6NU1okjQGSxgEZN8eBYKg==",
-			"dev": true,
-			"optional": true
+			"optional": true,
+			"peer": true
 		},
 		"merge-descriptors": {
 			"version": "1.0.1",
@@ -11720,12 +10978,6 @@
 			"integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==",
 			"dev": true
 		},
-		"merge2": {
-			"version": "1.4.1",
-			"resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz",
-			"integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==",
-			"dev": true
-		},
 		"methods": {
 			"version": "1.1.2",
 			"resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz",
@@ -11818,7 +11070,8 @@
 			"version": "3.7.1",
 			"resolved": "https://registry.npmjs.org/mongodb/-/mongodb-3.7.1.tgz",
 			"integrity": "sha512-iSVgexYr8ID0ieeNFUbRfQeOZxOchRck6kEDVySQRaa8VIw/1Pm+/LgcpZcl/BWV6nT0L8lP9qyl7dRPJ6mnLw==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"requires": {
 				"bl": "^2.2.1",
 				"bson": "^1.1.4",
@@ -12156,7 +11409,8 @@
 			"version": "1.1.7",
 			"resolved": "https://registry.npmjs.org/optional-require/-/optional-require-1.1.7.tgz",
 			"integrity": "sha512-cIeRZocXsZnZYn+SevbtSqNlLbeoS4mLzuNn4fvXRMDRNhTGg0sxuKXl0FnZCtnew85LorNxIbZp5OeliILhMw==",
-			"devOptional": true,
+			"optional": true,
+			"peer": true,
 			"requires": {
 				"require-at": "^1.0.6"
 			}
@@ -12586,7 +11840,8 @@
 		"punycode": {
 			"version": "2.1.1",
 			"resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
-			"integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
+			"integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==",
+			"devOptional": true
 		},
 		"qs": {
 			"version": "6.7.0",
@@ -12598,12 +11853,6 @@
 			"resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz",
 			"integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ=="
 		},
-		"queue-microtask": {
-			"version": "1.2.3",
-			"resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
-			"integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==",
-			"dev": true
-		},
 		"range-parser": {
 			"version": "1.2.1",
 			"resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz",
@@ -12714,18 +11963,14 @@
 			"version": "1.0.6",
 			"resolved": "https://registry.npmjs.org/require-at/-/require-at-1.0.6.tgz",
 			"integrity": "sha512-7i1auJbMUrXEAZCOQ0VNJgmcT2VOKPRl2YGJwgpHpC9CE91Mv4/4UYIUm4chGJaI381ZDq1JUicFii64Hapd8g==",
-			"devOptional": true
+			"optional": true,
+			"peer": true
 		},
 		"require-directory": {
 			"version": "2.1.1",
 			"resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
 			"integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I="
 		},
-		"require-from-string": {
-			"version": "2.0.2",
-			"resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz",
-			"integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw=="
-		},
 		"requires-port": {
 			"version": "1.0.0",
 			"resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz",
@@ -12756,12 +12001,6 @@
 			"integrity": "sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw==",
 			"dev": true
 		},
-		"reusify": {
-			"version": "1.0.4",
-			"resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz",
-			"integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==",
-			"dev": true
-		},
 		"rimraf": {
 			"version": "3.0.2",
 			"resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz",
@@ -12771,15 +12010,6 @@
 				"glob": "^7.1.3"
 			}
 		},
-		"run-parallel": {
-			"version": "1.2.0",
-			"resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz",
-			"integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==",
-			"dev": true,
-			"requires": {
-				"queue-microtask": "^1.2.2"
-			}
-		},
 		"safe-buffer": {
 			"version": "5.2.1",
 			"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz",
@@ -12794,8 +12024,8 @@
 			"version": "1.0.3",
 			"resolved": "https://registry.npmjs.org/saslprep/-/saslprep-1.0.3.tgz",
 			"integrity": "sha512-/MY/PEMbk2SuY5sScONwhUDsV2p77Znkb/q3nSVstq/yQzYJOH/Azh29p9oJLsl3LnQwSvZDKagDGBsBwSooag==",
-			"dev": true,
 			"optional": true,
+			"peer": true,
 			"requires": {
 				"sparse-bitfield": "^3.0.3"
 			}
@@ -12927,8 +12157,8 @@
 			"version": "3.0.3",
 			"resolved": "https://registry.npmjs.org/sparse-bitfield/-/sparse-bitfield-3.0.3.tgz",
 			"integrity": "sha1-/0rm5oZWBWuks+eSqzM004JzyhE=",
-			"dev": true,
 			"optional": true,
+			"peer": true,
 			"requires": {
 				"memory-pager": "^1.0.2"
 			}
@@ -13209,29 +12439,31 @@
 				"punycode": "^2.1.1"
 			}
 		},
-		"tsconfig-paths": {
-			"version": "3.11.0",
-			"resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.11.0.tgz",
-			"integrity": "sha512-7ecdYDnIdmv639mmDwslG6KQg1Z9STTz1j7Gcz0xa+nshh/gKDAHcPxRbWOsA3SPp0tXP2leTcY9Kw+NAkfZzA==",
+		"ts-node": {
+			"version": "10.2.1",
+			"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.2.1.tgz",
+			"integrity": "sha512-hCnyOyuGmD5wHleOQX6NIjJtYVIO8bPP8F2acWkB4W06wdlkgyvJtubO/I9NkI88hCFECbsEgoLc0VNkYmcSfw==",
+			"dev": true,
 			"requires": {
-				"@types/json5": "^0.0.29",
-				"json5": "^1.0.1",
-				"minimist": "^1.2.0",
-				"strip-bom": "^3.0.0"
+				"@cspotcode/source-map-support": "0.6.1",
+				"@tsconfig/node10": "^1.0.7",
+				"@tsconfig/node12": "^1.0.7",
+				"@tsconfig/node14": "^1.0.0",
+				"@tsconfig/node16": "^1.0.2",
+				"acorn": "^8.4.1",
+				"acorn-walk": "^8.1.1",
+				"arg": "^4.1.0",
+				"create-require": "^1.1.0",
+				"diff": "^4.0.1",
+				"make-error": "^1.1.1",
+				"yn": "3.1.1"
 			},
 			"dependencies": {
-				"json5": {
-					"version": "1.0.1",
-					"resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz",
-					"integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==",
-					"requires": {
-						"minimist": "^1.2.0"
-					}
-				},
-				"strip-bom": {
-					"version": "3.0.0",
-					"resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz",
-					"integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM="
+				"acorn-walk": {
+					"version": "8.2.0",
+					"resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz",
+					"integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==",
+					"dev": true
 				}
 			}
 		},
@@ -13447,6 +12679,7 @@
 			"version": "4.4.1",
 			"resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz",
 			"integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==",
+			"optional": true,
 			"requires": {
 				"punycode": "^2.1.0"
 			}
@@ -13495,11 +12728,6 @@
 				}
 			}
 		},
-		"validator": {
-			"version": "13.6.0",
-			"resolved": "https://registry.npmjs.org/validator/-/validator-13.6.0.tgz",
-			"integrity": "sha512-gVgKbdbHgtxpRyR8K0O6oFZPhhB5tT1jeEHZR0Znr9Svg03U0+r9DXWMrnRAB+HtCStDQKlaIZm42tVsVjqtjg=="
-		},
 		"vary": {
 			"version": "1.1.2",
 			"resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz",
diff --git a/util/package.json b/util/package.json
index 32204081..e1003114 100644
--- a/util/package.json
+++ b/util/package.json
@@ -8,7 +8,8 @@
 		"start": "npm run build && node dist/",
 		"test": "npm run build && jest",
 		"postinstall": "npm run build",
-		"build": "npx tsc -b ."
+		"build": "npx tsc -p .",
+		"typeorm": "node --require ts-node/register ./node_modules/typeorm/cli.js"
 	},
 	"repository": {
 		"type": "git",
@@ -28,22 +29,16 @@
 	},
 	"homepage": "https://docs.fosscord.com/",
 	"devDependencies": {
-		"@swc/cli": "^0.1.51",
-		"@swc/core": "^1.2.93",
 		"@types/amqplib": "^0.8.1",
 		"@types/jsonwebtoken": "^8.5.0",
-		"@types/mongoose-autopopulate": "^0.10.1",
 		"@types/multer": "^1.4.7",
 		"@types/node": "^14.17.9",
 		"@types/node-fetch": "^2.5.12",
-		"jest": "^27.0.6"
+		"jest": "^27.0.6",
+		"ts-node": "^10.2.1"
 	},
 	"dependencies": {
-		"ajv": "^8.6.2",
 		"amqplib": "^0.8.0",
-		"class-validator": "^0.13.1",
-		"dot-prop": "^6.0.1",
-		"env-paths": "^2.2.1",
 		"jsonwebtoken": "^8.5.1",
 		"lambert-server": "^1.2.11",
 		"missing-native-js-functions": "^1.2.17",
@@ -54,7 +49,6 @@
 		"pg": "^8.7.1",
 		"reflect-metadata": "^0.1.13",
 		"sqlite3": "^5.0.2",
-		"tsconfig-paths": "^3.11.0",
 		"typeorm": "^0.2.37",
 		"typescript": "^4.4.2",
 		"typescript-json-schema": "^0.50.1"
diff --git a/util/src/entities/AuditLog.ts b/util/src/entities/AuditLog.ts
index ae9feb76..4b81ed6a 100644
--- a/util/src/entities/AuditLog.ts
+++ b/util/src/entities/AuditLog.ts
@@ -55,10 +55,7 @@ export class AuditLog extends BaseClass {
 	@ManyToOne(() => User, (user: User) => user.id)
 	user: User;
 
-	@Column({
-		type: "simple-enum",
-		enum: AuditLogEvents,
-	})
+	@Column({ type: "int" })
 	action_type: AuditLogEvents;
 
 	@Column({ type: "simple-json", nullable: true })
diff --git a/util/src/entities/BaseClass.ts b/util/src/entities/BaseClass.ts
index beccf04b..d20078e5 100644
--- a/util/src/entities/BaseClass.ts
+++ b/util/src/entities/BaseClass.ts
@@ -1,19 +1,8 @@
 import "reflect-metadata";
-import {
-	BaseEntity,
-	BeforeInsert,
-	BeforeUpdate,
-	EntityMetadata,
-	FindConditions,
-	ObjectIdColumn,
-	PrimaryColumn,
-} from "typeorm";
+import { BaseEntity, EntityMetadata, FindConditions, ObjectIdColumn, PrimaryColumn } from "typeorm";
 import { Snowflake } from "../util/Snowflake";
 import "missing-native-js-functions";
 
-// TODO use class-validator https://typeorm.io/#/validation with class annotators (isPhone/isEmail) combined with types from typescript-json-schema
-// btw. we don't use class-validator for everything, because we need to explicitly set the type instead of deriving it from typescript also it doesn't easily support nested objects
-
 export class BaseClassWithoutId extends BaseEntity {
 	constructor(props?: any) {
 		super();
@@ -42,7 +31,7 @@ export class BaseClassWithoutId extends BaseEntity {
 		for (const key in props) {
 			if (!properties.has(key)) continue;
 			// @ts-ignore
-			const setter = this[`set${key.capitalize()}`];
+			const setter = this[`set${key.capitalize()}`]; // use setter function if it exists
 
 			if (setter) {
 				setter.call(this, props[key]);
@@ -53,12 +42,6 @@ export class BaseClassWithoutId extends BaseEntity {
 		}
 	}
 
-	@BeforeUpdate()
-	@BeforeInsert()
-	validate() {
-		return this;
-	}
-
 	toJSON(): any {
 		return Object.fromEntries(
 			this.metadata.columns // @ts-ignore
@@ -76,42 +59,6 @@ export class BaseClassWithoutId extends BaseEntity {
 		const repository = this.getRepository();
 		return repository.decrement(conditions, propertyPath, value);
 	}
-
-	// static async delete<T>(criteria: FindConditions<T>, options?: RemoveOptions) {
-	// 	if (!criteria) throw new Error("You need to specify delete criteria");
-
-	// 	const repository = this.getRepository();
-	// 	const promises = repository.metadata.relations.map(async (x) => {
-	// 		if (x.orphanedRowAction !== "delete") return;
-
-	// 		const foreignKey =
-	// 			x.foreignKeys.find((key) => key.entityMetadata === repository.metadata) ||
-	// 			x.inverseRelation?.foreignKeys[0]; // find foreign key for this entity
-	// 		if (!foreignKey) {
-	// 			throw new Error(
-	// 				`Foreign key not found for entity ${repository.metadata.name} in relation ${x.propertyName}`
-	// 			);
-	// 		}
-	// 		const id = (criteria as any)[foreignKey.referencedColumnNames[0]];
-	// 		if (!id) throw new Error("id missing in criteria options " + foreignKey.referencedColumnNames);
-
-	// 		if (x.relationType === "many-to-many") {
-	// 			return getConnection()
-	// 				.createQueryBuilder()
-	// 				.relation(this, x.propertyName)
-	// 				.of(id)
-	// 				.remove({ [foreignKey.columnNames[0]]: id });
-	// 		} else if (
-	// 			x.relationType === "one-to-one" ||
-	// 			x.relationType === "many-to-one" ||
-	// 			x.relationType === "one-to-many"
-	// 		) {
-	// 			return (x.inverseEntityMetadata.target as any).delete({ [foreignKey.columnNames[0]]: id });
-	// 		}
-	// 	});
-	// 	await Promise.all(promises);
-	// 	return super.delete(criteria, options);
-	// }
 }
 
 export const PrimaryIdColumn = process.env.DATABASE?.startsWith("mongodb") ? ObjectIdColumn : PrimaryColumn;
diff --git a/util/src/entities/Channel.ts b/util/src/entities/Channel.ts
index 51d8b026..bd2e5a58 100644
--- a/util/src/entities/Channel.ts
+++ b/util/src/entities/Channel.ts
@@ -39,7 +39,7 @@ export class Channel extends BaseClass {
 	@Column({ type: "text", nullable: true })
 	icon?: string | null;
 
-	@Column({ type: "simple-enum", enum: ChannelType })
+	@Column({ type: "int" })
 	type: ChannelType;
 
 	@OneToMany(() => Recipient, (recipient: Recipient) => recipient.channel, {
diff --git a/util/src/entities/Config.ts b/util/src/entities/Config.ts
index 813649ac..6760187f 100644
--- a/util/src/entities/Config.ts
+++ b/util/src/entities/Config.ts
@@ -64,6 +64,7 @@ export interface ConfigValue {
 		};
 		guild: {
 			maxRoles: number;
+			maxEmojis: number;
 			maxMembers: number;
 			maxChannels: number;
 			maxChannelsInCategory: number;
@@ -188,6 +189,7 @@ export const DefaultConfigOptions: ConfigValue = {
 		},
 		guild: {
 			maxRoles: 250,
+			maxEmojis: 50, // TODO: max emojis per guild per nitro level
 			maxMembers: 250000,
 			maxChannels: 500,
 			maxChannelsInCategory: 50,
diff --git a/util/src/entities/Emoji.ts b/util/src/entities/Emoji.ts
index a252d9f4..03218375 100644
--- a/util/src/entities/Emoji.ts
+++ b/util/src/entities/Emoji.ts
@@ -1,4 +1,5 @@
-import { Column, Entity, JoinColumn, ManyToOne } from "typeorm";
+import { Column, Entity, JoinColumn, ManyToOne, RelationId } from "typeorm";
+import { User } from ".";
 import { BaseClass } from "./BaseClass";
 import { Guild } from "./Guild";
 import { Role } from "./Role";
@@ -20,6 +21,14 @@ export class Emoji extends BaseClass {
 	})
 	guild: Guild;
 
+	@Column({ nullable: true })
+	@RelationId((emoji: Emoji) => emoji.user)
+	user_id: string;
+
+	@JoinColumn({ name: "user_id" })
+	@ManyToOne(() => User)
+	user: User;
+
 	@Column()
 	managed: boolean;
 
@@ -28,4 +37,7 @@ export class Emoji extends BaseClass {
 
 	@Column()
 	require_colons: boolean;
+
+	@Column({ type: "simple-array" })
+	roles: string[]; // roles this emoji is whitelisted to (new discord feature?)
 }
diff --git a/util/src/entities/Guild.ts b/util/src/entities/Guild.ts
index 35595191..157f0921 100644
--- a/util/src/entities/Guild.ts
+++ b/util/src/entities/Guild.ts
@@ -258,14 +258,6 @@ export class Guild extends BaseClass {
 	unavailable?: boolean;
 
 	@Column({ nullable: true })
-	@RelationId((guild: Guild) => guild.vanity_url)
-	vanity_url_code?: string;
-
-	@JoinColumn({ name: "vanity_url_code" })
-	@ManyToOne(() => Invite)
-	vanity_url?: Invite;
-
-	@Column({ nullable: true })
 	verification_level?: number;
 
 	@Column({ type: "simple-json" })
diff --git a/util/src/entities/Invite.ts b/util/src/entities/Invite.ts
index 82556fab..b3e00957 100644
--- a/util/src/entities/Invite.ts
+++ b/util/src/entities/Invite.ts
@@ -1,6 +1,6 @@
-import { Column, Entity, JoinColumn, ManyToOne, RelationId } from "typeorm";
+import { Column, Entity, JoinColumn, ManyToOne, RelationId, PrimaryColumn } from "typeorm";
 import { Member } from "./Member";
-import { BaseClass, PrimaryIdColumn } from "./BaseClass";
+import { BaseClassWithoutId } from "./BaseClass";
 import { Channel } from "./Channel";
 import { Guild } from "./Guild";
 import { User } from "./User";
@@ -8,8 +8,8 @@ import { User } from "./User";
 export const PublicInviteRelation = ["inviter", "guild", "channel"];
 
 @Entity("invites")
-export class Invite extends BaseClass {
-	@PrimaryIdColumn()
+export class Invite extends BaseClassWithoutId {
+	@PrimaryColumn()
 	code: string;
 
 	@Column()
@@ -71,6 +71,9 @@ export class Invite extends BaseClass {
 	@Column({ nullable: true })
 	target_user_type?: number;
 
+	@Column({ nullable: true})
+	vanity_url?: boolean;
+
 	static async joinGuild(user_id: string, code: string) {
 		const invite = await Invite.findOneOrFail({ code });
 		if (invite.uses++ >= invite.max_uses && invite.max_uses !== 0) await Invite.delete({ code });
diff --git a/util/src/entities/Message.ts b/util/src/entities/Message.ts
index 04c3c7aa..63cd6ad3 100644
--- a/util/src/entities/Message.ts
+++ b/util/src/entities/Message.ts
@@ -46,9 +46,6 @@ export enum MessageType {
 
 @Entity("messages")
 export class Message extends BaseClass {
-	@Column()
-	id: string;
-
 	@Column({ nullable: true })
 	@RelationId((message: Message) => message.channel)
 	channel_id: string;
@@ -151,7 +148,7 @@ export class Message extends BaseClass {
 	@Column({ nullable: true })
 	pinned?: boolean;
 
-	@Column({ type: "simple-enum", enum: MessageType })
+	@Column({ type: "int" })
 	type: MessageType;
 
 	@Column({ type: "simple-json", nullable: true })
diff --git a/util/src/entities/RateLimit.ts b/util/src/entities/RateLimit.ts
index fa9c32c1..f5916f6b 100644
--- a/util/src/entities/RateLimit.ts
+++ b/util/src/entities/RateLimit.ts
@@ -3,9 +3,6 @@ import { BaseClass } from "./BaseClass";
 
 @Entity("rate_limits")
 export class RateLimit extends BaseClass {
-	@Column()
-	id: "global" | "error" | string; // channel_239842397 | guild_238927349823 | webhook_238923423498
-
 	@Column() // no relation as it also
 	executor_id: string;
 
diff --git a/util/src/entities/ReadState.ts b/util/src/entities/ReadState.ts
index 68e867a0..89480e83 100644
--- a/util/src/entities/ReadState.ts
+++ b/util/src/entities/ReadState.ts
@@ -1,4 +1,4 @@
-import { Column, Entity, JoinColumn, ManyToOne, RelationId } from "typeorm";
+import { Column, Entity, Index, JoinColumn, ManyToOne, RelationId } from "typeorm";
 import { BaseClass } from "./BaseClass";
 import { Channel } from "./Channel";
 import { Message } from "./Message";
@@ -9,8 +9,9 @@ import { User } from "./User";
 // public read receipt ≥ notification cursor ≥ private fully read marker
 
 @Entity("read_states")
+@Index(["channel_id", "user_id"], { unique: true })
 export class ReadState extends BaseClass {
-	@Column({ nullable: true })
+	@Column()
 	@RelationId((read_state: ReadState) => read_state.channel)
 	channel_id: string;
 
@@ -20,7 +21,7 @@ export class ReadState extends BaseClass {
 	})
 	channel: Channel;
 
-	@Column({ nullable: true })
+	@Column()
 	@RelationId((read_state: ReadState) => read_state.user)
 	user_id: string;
 
@@ -35,15 +36,15 @@ export class ReadState extends BaseClass {
 	last_message_id: string;
 
 	@JoinColumn({ name: "last_message_id" })
-	@ManyToOne(() => Message)
+	@ManyToOne(() => Message, { nullable: true })
 	last_message?: Message;
 
 	@Column({ nullable: true })
 	last_pin_timestamp?: Date;
 
-	@Column()
+	@Column({ nullable: true })
 	mention_count: number;
 
-	@Column()
+	@Column({ nullable: true })
 	manual: boolean;
 }
diff --git a/util/src/entities/Relationship.ts b/util/src/entities/Relationship.ts
index e016b36b..c3592c76 100644
--- a/util/src/entities/Relationship.ts
+++ b/util/src/entities/Relationship.ts
@@ -35,7 +35,7 @@ export class Relationship extends BaseClass {
 	@Column({ nullable: true })
 	nickname?: string;
 
-	@Column({ type: "simple-enum", enum: RelationshipType })
+	@Column({ type: "int" })
 	type: RelationshipType;
 
 	toPublicRelationship() {
diff --git a/util/src/entities/Sticker.ts b/util/src/entities/Sticker.ts
index ab224d1d..036ff2d0 100644
--- a/util/src/entities/Sticker.ts
+++ b/util/src/entities/Sticker.ts
@@ -36,9 +36,9 @@ export class Sticker extends BaseClass {
 	})
 	guild?: Guild;
 
-	@Column({ type: "simple-enum", enum: StickerType })
+	@Column({ type: "int" })
 	type: StickerType;
 
-	@Column({ type: "simple-enum", enum: StickerFormatType })
+	@Column({ type: "int" })
 	format_type: StickerFormatType;
 }
diff --git a/util/src/entities/TeamMember.ts b/util/src/entities/TeamMember.ts
index bdfdccf0..b726e1e8 100644
--- a/util/src/entities/TeamMember.ts
+++ b/util/src/entities/TeamMember.ts
@@ -9,7 +9,7 @@ export enum TeamMemberState {
 
 @Entity("team_members")
 export class TeamMember extends BaseClass {
-	@Column({ type: "simple-enum", enum: TeamMemberState })
+	@Column({ type: "int" })
 	membership_state: TeamMemberState;
 
 	@Column({ type: "simple-array" })
diff --git a/util/src/entities/User.ts b/util/src/entities/User.ts
index 97564af3..04f1e9cb 100644
--- a/util/src/entities/User.ts
+++ b/util/src/entities/User.ts
@@ -198,7 +198,7 @@ export class User extends BaseClass {
 		// randomly generates a discriminator between 1 and 9999 and checks max five times if it already exists
 		// if it all five times already exists, abort with USERNAME_TOO_MANY_USERS error
 		// else just continue
-		// TODO: is there any better way to generate a random discriminator only once, without checking if it already exists in the mongodb database?
+		// TODO: is there any better way to generate a random discriminator only once, without checking if it already exists in the database?
 		for (let tries = 0; tries < 5; tries++) {
 			discriminator = Math.randomIntBetween(1, 9999).toString().padStart(4, "0");
 			exists = await User.findOne({ where: { discriminator, username: username }, select: ["id"] });
@@ -219,7 +219,7 @@ export class User extends BaseClass {
 		// if nsfw_allowed is null/undefined it'll require date_of_birth to set it to true/false
 		const language = req.language === "en" ? "en-US" : req.language || "en-US";
 
-		const user = await new User({
+		const user = new User({
 			created_at: new Date(),
 			username: username,
 			discriminator,
@@ -246,7 +246,9 @@ export class User extends BaseClass {
 			},
 			settings: { ...defaultSettings, locale: language },
 			fingerprints: [],
-		}).save();
+		});
+
+		await user.save();
 
 		if (Config.get().guild.autoJoin.enabled) {
 			for (const guild of Config.get().guild.autoJoin.guilds || []) {
diff --git a/util/src/entities/Webhook.ts b/util/src/entities/Webhook.ts
index 8382435f..89538417 100644
--- a/util/src/entities/Webhook.ts
+++ b/util/src/entities/Webhook.ts
@@ -12,10 +12,7 @@ export enum WebhookType {
 
 @Entity("webhooks")
 export class Webhook extends BaseClass {
-	@Column()
-	id: string;
-
-	@Column({ type: "simple-enum", enum: WebhookType })
+	@Column({ type: "int" })
 	type: WebhookType;
 
 	@Column({ nullable: true })
diff --git a/util/src/index.ts b/util/src/index.ts
index fc00d46b..ae0f7e54 100644
--- a/util/src/index.ts
+++ b/util/src/index.ts
@@ -1,12 +1,6 @@
 import "reflect-metadata";
 
-// export * as Constants from "../util/Constants";
 export * from "./util/index";
 export * from "./interfaces/index";
 export * from "./entities/index";
 export * from "./dtos/index";
-
-// import Config from "../util/Config";
-// import db, { MongooseCache, toObject } from "./util/Database";
-
-// export { Config };
diff --git a/util/src/interfaces/Event.ts b/util/src/interfaces/Event.ts
index 03099bbb..3c8ab8ab 100644
--- a/util/src/interfaces/Event.ts
+++ b/util/src/interfaces/Event.ts
@@ -185,8 +185,8 @@ export interface GuildBanRemoveEvent extends Event {
 	};
 }
 
-export interface GuildEmojiUpdateEvent extends Event {
-	event: "GUILD_EMOJI_UPDATE";
+export interface GuildEmojisUpdateEvent extends Event {
+	event: "GUILD_EMOJIS_UPDATE";
 	data: {
 		guild_id: string;
 		emojis: Emoji[];
@@ -459,7 +459,7 @@ export type EventData =
 	| GuildDeleteEvent
 	| GuildBanAddEvent
 	| GuildBanRemoveEvent
-	| GuildEmojiUpdateEvent
+	| GuildEmojisUpdateEvent
 	| GuildIntegrationUpdateEvent
 	| GuildMemberAddEvent
 	| GuildMemberRemoveEvent
@@ -552,7 +552,7 @@ export type EVENT =
 	| "GUILD_DELETE"
 	| "GUILD_BAN_ADD"
 	| "GUILD_BAN_REMOVE"
-	| "GUILD_EMOJI_UPDATE"
+	| "GUILD_EMOJIS_UPDATE"
 	| "GUILD_INTEGRATIONS_UPDATE"
 	| "GUILD_MEMBER_ADD"
 	| "GUILD_MEMBER_REMOVE"
diff --git a/util/src/migrations/1633864260873-EmojiRoles.ts b/util/src/migrations/1633864260873-EmojiRoles.ts
new file mode 100644
index 00000000..f0d709f2
--- /dev/null
+++ b/util/src/migrations/1633864260873-EmojiRoles.ts
@@ -0,0 +1,13 @@
+import { MigrationInterface, QueryRunner } from "typeorm";
+
+export class EmojiRoles1633864260873 implements MigrationInterface {
+	name = "EmojiRoles1633864260873";
+
+	public async up(queryRunner: QueryRunner): Promise<void> {
+		await queryRunner.query(`ALTER TABLE "emojis" ADD "roles" text NOT NULL DEFAULT ''`);
+	}
+
+	public async down(queryRunner: QueryRunner): Promise<void> {
+		await queryRunner.query(`ALTER TABLE "emojis" DROP COLUMN column_name "roles"`);
+	}
+}
diff --git a/util/src/migrations/1633864669243-EmojiUser.ts b/util/src/migrations/1633864669243-EmojiUser.ts
new file mode 100644
index 00000000..982405d7
--- /dev/null
+++ b/util/src/migrations/1633864669243-EmojiUser.ts
@@ -0,0 +1,23 @@
+import { MigrationInterface, QueryRunner } from "typeorm";
+
+export class EmojiUser1633864669243 implements MigrationInterface {
+	name = "EmojiUser1633864669243";
+
+	public async up(queryRunner: QueryRunner): Promise<void> {
+		await queryRunner.query(`ALTER TABLE "emojis" ADD "user_id" varchar`);
+		try {
+			await queryRunner.query(
+				`ALTER TABLE "emojis" ADD CONSTRAINT FK_fa7ddd5f9a214e28ce596548421 FOREIGN KEY (user_id) REFERENCES users(id)`
+			);
+		} catch (error) {
+			console.error(
+				"sqlite doesn't support altering foreign keys: https://stackoverflow.com/questions/1884818/how-do-i-add-a-foreign-key-to-an-existing-sqlite-table"
+			);
+		}
+	}
+
+	public async down(queryRunner: QueryRunner): Promise<void> {
+		await queryRunner.query(`ALTER TABLE "emojis" DROP COLUMN column_name "user_id"`);
+		await queryRunner.query(`ALTER TABLE "emojis" DROP CONSTRAINT FK_fa7ddd5f9a214e28ce596548421`);
+	}
+}
diff --git a/util/src/migrations/1633881705509-VanityInvite.ts b/util/src/migrations/1633881705509-VanityInvite.ts
new file mode 100644
index 00000000..af9b98ae
--- /dev/null
+++ b/util/src/migrations/1633881705509-VanityInvite.ts
@@ -0,0 +1,17 @@
+import { MigrationInterface, QueryRunner } from "typeorm";
+
+export class VanityInvite1633881705509 implements MigrationInterface {
+	public async up(queryRunner: QueryRunner): Promise<void> {
+		try {
+			await queryRunner.query(`ALTER TABLE "emojis" DROP COLUMN vanity_url_code`);
+			await queryRunner.query(`ALTER TABLE "emojis" DROP CONSTRAINT FK_c2c1809d79eb120ea0cb8d342ad`);
+		} catch (error) {}
+	}
+
+	public async down(queryRunner: QueryRunner): Promise<void> {
+		await queryRunner.query(`ALTER TABLE "emojis" ADD vanity_url_code varchar`);
+		await queryRunner.query(
+			`ALTER TABLE "emojis" ADD CONSTRAINT FK_c2c1809d79eb120ea0cb8d342ad FOREIGN KEY ("vanity_url_code") REFERENCES "invites"("code") ON DELETE NO ACTION ON UPDATE NO ACTION`
+		);
+	}
+}
diff --git a/util/src/migrations/migrate_db_engine.js b/util/src/migrations/migrate_db_engine.js
new file mode 100644
index 00000000..eab30bc4
--- /dev/null
+++ b/util/src/migrations/migrate_db_engine.js
@@ -0,0 +1,106 @@
+const { config } = require("dotenv");
+config();
+const { createConnection } = require("typeorm");
+const { initDatabase } = require("../../dist/util/Database");
+require("missing-native-js-functions");
+const {
+	Application,
+	Attachment,
+	Ban,
+	Channel,
+	ConnectedAccount,
+	Emoji,
+	Guild,
+	Invite,
+	Member,
+	Message,
+	ReadState,
+	Recipient,
+	Relationship,
+	Role,
+	Sticker,
+	Team,
+	TeamMember,
+	Template,
+	User,
+	VoiceState,
+	Webhook,
+} = require("../../dist/entities/index");
+
+async function main() {
+	if (!process.env.TO) throw new Error("TO database env connection string not set");
+
+	// manually arrange them because of foreign keys
+	const entities = [
+		User,
+		Guild,
+		Channel,
+		Invite,
+		Role,
+		Ban,
+		Application,
+		Emoji,
+		ConnectedAccount,
+		Member,
+		ReadState,
+		Recipient,
+		Relationship,
+		Sticker,
+		Team,
+		TeamMember,
+		Template,
+		VoiceState,
+		Webhook,
+		Message,
+		Attachment,
+	];
+
+	const oldDB = await initDatabase();
+
+	const type = process.env.TO.includes("://") ? process.env.TO.split(":")[0]?.replace("+srv", "") : "sqlite";
+	const isSqlite = type.includes("sqlite");
+
+	// @ts-ignore
+	const oldDB = await createConnection({
+		type,
+		url: isSqlite ? undefined : process.env.TO,
+		database: isSqlite ? process.env.TO : undefined,
+		entities,
+		name: "old",
+	});
+	let i = 0;
+
+	try {
+		for (const entity of entities) {
+			const entries = await oldDB.manager.find(entity);
+
+			// @ts-ignore
+			console.log("migrating " + entries.length + " " + entity.name + " ...");
+
+			for (const entry of entries) {
+				console.log(i++);
+
+				try {
+					await newDB.manager.insert(entity, entry);
+				} catch (error) {
+					try {
+						if (!entry.id) throw new Error("object doesn't have a unique id: " + entry);
+						await newDB.manager.update(entity, { id: entry.id }, entry);
+					} catch (error) {
+						console.error("couldn't migrate " + i + " " + entity.name, error);
+					}
+				}
+			}
+
+			// @ts-ignore
+			console.log("migrated " + entries.length + " " + entity.name);
+		}
+	} catch (error) {
+		console.error(error.message);
+	}
+
+	console.log("SUCCESS migrated all data");
+	await newDB.close();
+}
+
+main().caught();
diff --git a/util/src/migrations/migrate_db_engine.ts b/util/src/migrations/migrate_db_engine.ts
deleted file mode 100644
index 33024a8d..00000000
--- a/util/src/migrations/migrate_db_engine.ts
+++ /dev/null
@@ -1,129 +0,0 @@
-import { config } from "dotenv";
-config();
-import { BaseEntity, createConnection, EntityTarget } from "typeorm";
-import { initDatabase } from "../util/Database";
-import "missing-native-js-functions";
-import {
-	Application,
-	Attachment,
-	Ban,
-	Channel,
-	ConnectedAccount,
-	defaultSettings,
-	Emoji,
-	Guild,
-	Invite,
-	Member,
-	Message,
-	RateLimit,
-	ReadState,
-	Recipient,
-	Relationship,
-	Role,
-	Sticker,
-	Team,
-	TeamMember,
-	Template,
-	User,
-	VoiceState,
-	Webhook,
-} from "..";
-
-async function main() {
-	if (!process.env.FROM) throw new Error("FROM database env connection string not set");
-
-	// manually arrange them because of foreign key
-	const entities = [
-		User,
-		Guild,
-		Channel,
-		Invite,
-		Role,
-		Ban,
-		Application,
-		Emoji,
-		ConnectedAccount,
-		Member,
-		ReadState,
-		Recipient,
-		Relationship,
-		Sticker,
-		Team,
-		TeamMember,
-		Template,
-		VoiceState,
-		Webhook,
-		Message,
-		Attachment,
-	];
-
-	const newDB = await initDatabase();
-
-	// @ts-ignore
-	const oldDB = await createConnection({
-		type: process.env.FROM.split(":")[0]?.replace("+srv", ""),
-		url: process.env.FROM,
-		entities,
-		name: "old",
-	});
-	let i = 0;
-
-	try {
-		for (const e of entities) {
-			const entity = e as EntityTarget<any>;
-			const entries = await oldDB.manager.find(entity);
-			//@ts-ignore
-			console.log("migrated " + entries.length + " " + entity.name);
-
-			for (const entry of entries) {
-				console.log(i++);
-
-				if (entry instanceof User) {
-					console.log("instance of User");
-					if (entry.bio == null) entry.bio = "";
-					if (entry.rights == null) entry.rights = "0";
-					if (entry.disabled == null) entry.disabled = false;
-					if (entry.fingerprints == null) entry.fingerprints = [];
-					if (entry.deleted == null) entry.deleted = false;
-					if (entry.data == null) {
-						entry.data = {
-							valid_tokens_since: new Date(0),
-							hash: undefined,
-						};
-						// @ts-ignore
-						if (entry.user_data) {
-							// TODO: relationships
-							entry.data = {
-								// @ts-ignore
-								valid_tokens_since: entry.user_data.valid_tokens_since, // @ts-ignore
-								hash: entry.user_data.hash,
-							};
-						}
-					}
-					// @ts-ignore
-					if (entry.settings == null) {
-						entry.settings = defaultSettings;
-						// @ts-ignore
-						if (entry.user_data) entry.settings = entry.user_settings;
-					}
-				}
-
-				// try {
-				await newDB.manager.insert(entity, entry);
-				// } catch (error) {
-				// 	if (!entry.id) throw new Error("object doesn't have a unique id: " + entry);
-				// 	await newDB.manager.update(entity, { id: entry.id }, entry);
-				// }
-			}
-			// @ts-ignore
-			console.log("migrated all " + entity.name);
-		}
-	} catch (error) {
-		console.error((error as any).message);
-	}
-
-	console.log("SUCCESS migrated all data");
-	await newDB.close();
-}
-
-main().caught();
diff --git a/util/src/util/Config.ts b/util/src/util/Config.ts
index eeeaa2ce..704f3f2f 100644
--- a/util/src/util/Config.ts
+++ b/util/src/util/Config.ts
@@ -12,7 +12,6 @@ export const Config = {
 		if (config) return config;
 		pairs = await ConfigEntity.find();
 		config = pairsToConfig(pairs);
-		console.log(config.guild.autoJoin);
 
 		return this.set((config || {}).merge(DefaultConfigOptions));
 	},
diff --git a/util/src/util/Rights.ts b/util/src/util/Rights.ts
index a266e4f7..5edd9142 100644
--- a/util/src/util/Rights.ts
+++ b/util/src/util/Rights.ts
@@ -30,7 +30,7 @@ export class Rights extends BitField {
 		MANAGE_MESSAGES: BitFlag(3), // Can't see other messages but delete/edit them in channels that they can see
 		MANAGE_RATE_LIMITS: BitFlag(4),
 		MANAGE_ROUTING: BitFlag(5), // can create custom message routes to any channel/guild
-		MANAGE_TICKETS: BitFlag(6),
+		MANAGE_TICKETS: BitFlag(6), // can respond to and resolve support tickets
 		MANAGE_USERS: BitFlag(7),
 		ADD_MEMBERS: BitFlag(8), // can manually add any members in their guilds
 		BYPASS_RATE_LIMITS: BitFlag(9),
@@ -39,7 +39,7 @@ export class Rights extends BitField {
 		CREATE_DMS: BitFlag(12),
 		CREATE_DM_GROUPS: BitFlag(13),
 		CREATE_GUILDS: BitFlag(14),
-		CREATE_INVITES: BitFlag(15),
+		CREATE_INVITES: BitFlag(15), // can create mass invites in the guilds that they have CREATE_INSTANT_INVITE
 		CREATE_ROLES: BitFlag(16),
 		CREATE_TEMPLATES: BitFlag(17),
 		CREATE_WEBHOOKS: BitFlag(18),
@@ -50,9 +50,13 @@ export class Rights extends BitField {
 		SELF_EDIT_MESSAGES: BitFlag(23),
 		SELF_EDIT_NAME: BitFlag(24),
 		SEND_MESSAGES: BitFlag(25),
-		USE_SCREEN: BitFlag(26),
+		USE_ACTIVITIES: BitFlag(26), // use (game) activities in voice channels (e.g. Watch together)
 		USE_VIDEO: BitFlag(27),
 		USE_VOICE: BitFlag(28),
+		INVITE_USERS: BitFlag(29), // can create user-specific invites in the guilds that they have INVITE_USERS
+		SELF_DELETE_DISABLE: BitFlag(30), // can disable/delete own account
+		DEBTABLE: BitFlag(31), // can use pay-to-use features
+		CREDITABLE: BitFlag(32) // can receive money from monetisation related features
 	};
 
 	any(permission: RightResolvable, checkOperator = true) {
diff --git a/util/src/util/TraverseDirectory.ts b/util/src/util/TraverseDirectory.ts
new file mode 100644
index 00000000..275b7dcc
--- /dev/null
+++ b/util/src/util/TraverseDirectory.ts
@@ -0,0 +1,10 @@
+import { Server, traverseDirectory } from "lambert-server";
+
+const DEFAULT_FILTER = /^([^\.].*)(?<!\.d)\.(js)$/;
+
+export function registerRoutes(server: Server, root: string) {
+	return traverseDirectory(
+		{ dirname: root, recursive: true, filter: DEFAULT_FILTER },
+		server.registerRoute.bind(server, root)
+	);
+}
diff --git a/util/src/util/cdn.ts b/util/src/util/cdn.ts
index 2de23f5d..4dd0078a 100644
--- a/util/src/util/cdn.ts
+++ b/util/src/util/cdn.ts
@@ -26,7 +26,7 @@ export async function uploadFile(path: string, file: Express.Multer.File) {
 }
 
 export async function handleFile(path: string, body?: string): Promise<string | undefined> {
-	if (!body || !body.startsWith("data:")) return body;
+	if (!body || !body.startsWith("data:")) return undefined;
 	try {
 		const mimetype = body.split(":")[1].split(";")[0];
 		const buffer = Buffer.from(body.split(",")[1], "base64");
diff --git a/util/src/util/index.ts b/util/src/util/index.ts
index 67583635..c5703468 100644
--- a/util/src/util/index.ts
+++ b/util/src/util/index.ts
@@ -17,3 +17,4 @@ export * from "./Rights";
 export * from "./Snowflake";
 export * from "./String";
 export * from "./Array";
+export * from "./TraverseDirectory";
diff --git a/util/tsconfig.json b/util/tsconfig.json
index cbd5db32..0398ce9a 100644
--- a/util/tsconfig.json
+++ b/util/tsconfig.json
@@ -1,10 +1,10 @@
 {
-	"include": ["src/**/*.ts", "tests/Test.ts"],
+	"include": ["src/**/*.ts"],
 	"compilerOptions": {
 		/* Visit https://aka.ms/tsconfig.json to read more about this file */
 
 		/* Basic Options */
-		"incremental": true,                   /* Enable incremental compilation */
+		"incremental": true /* Enable incremental compilation */,
 		"target": "ES6" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */,
 		"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */,
 		"lib": ["ES2021"] /* Specify library files to be included in the compilation. */,