@paralect/hive 0.1.9 → 0.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/starter/src/app.js
CHANGED
|
@@ -18,14 +18,15 @@ import requestLogger from "koa-logger";
|
|
|
18
18
|
import db from "db";
|
|
19
19
|
import socketIo from "socketIo";
|
|
20
20
|
import mount from "koa-mount";
|
|
21
|
-
import routes from "routes";
|
|
22
21
|
import get from "resources/health/endpoints/get";
|
|
23
|
-
import scheduler from "./scheduler";
|
|
24
22
|
|
|
25
23
|
const main = async () => {
|
|
26
24
|
await config.init();
|
|
27
25
|
await db.init();
|
|
28
26
|
|
|
27
|
+
const routes = (await import("routes")).default;
|
|
28
|
+
const scheduler = (await import("./scheduler")).default;
|
|
29
|
+
|
|
29
30
|
process.on("unhandledRejection", (reason, p) => {
|
|
30
31
|
console.trace(reason.stack);
|
|
31
32
|
logger.error(reason.stack);
|
|
@@ -2,13 +2,10 @@ import { z } from 'zod';
|
|
|
2
2
|
import dbSchema from 'helpers/schema/db.schema';
|
|
3
3
|
|
|
4
4
|
export default dbSchema.extend({
|
|
5
|
-
_id: z.string(),
|
|
6
|
-
createdOn: z.date(),
|
|
7
|
-
updatedOn: z.date(),
|
|
8
5
|
user: z.object({
|
|
9
6
|
_id: z.string(),
|
|
10
7
|
}),
|
|
11
8
|
token: z.string(),
|
|
12
9
|
otp: z.string().nullable().optional(),
|
|
13
10
|
metadata: z.object({}).optional()
|
|
14
|
-
});
|
|
11
|
+
});
|