blob: e326dee10ae72eaee2822965cd98d1c8e68d9123 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
import { performance } from "perf_hooks";
import { Guild, Relationship, RelationshipType } from "./entities";
import { User } from "./entities/User";
import { initDatabase } from "./util";
initDatabase().then(async (x) => {
try {
const user = await new User({
guilds: [],
discriminator: "1",
username: "test",
flags: "0",
public_flags: "0",
id: "0",
}).save();
user.relationships = [new Relationship({ type: RelationshipType.friends })];
user.save();
} catch (error) {
console.error(error);
}
});
|