diff options
author | Catalan Lover <48515417+FSG-Cat@users.noreply.github.com> | 2022-08-23 23:50:01 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-23 23:50:01 +0200 |
commit | d63451b3fe6c0c6ab175adec82361834bb3633f5 (patch) | |
tree | b738ee25bf9819300e1802ba9a8e2813e9dc2588 /scripts/benchmark.js | |
parent | Merge pull request #1 from FSG-Cat/FSG-Cat-patch-1 (diff) | |
parent | Check Captcha (diff) | |
download | server-d63451b3fe6c0c6ab175adec82361834bb3633f5.tar.xz |
Merge branch 'fosscord:staging' into Bug-Report-Template
Diffstat (limited to 'scripts/benchmark.js')
-rw-r--r-- | scripts/benchmark.js | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/scripts/benchmark.js b/scripts/benchmark.js index e7435191..53db92c5 100644 --- a/scripts/benchmark.js +++ b/scripts/benchmark.js @@ -3,9 +3,7 @@ const Models = require("../dist/entities"); const { PrimaryColumn } = require("typeorm"); function shouldIncludeEntity(name) { - return ![Models.BaseClassWithoutId, PrimaryColumn, Models.BaseClass, Models.PrimaryGeneratedColumn] - .map((x) => x?.name) - .includes(name); + return ![Models.BaseClassWithoutId, PrimaryColumn, Models.BaseClass, Models.PrimaryGeneratedColumn].map((x) => x?.name).includes(name); } async function main() { @@ -14,7 +12,7 @@ async function main() { type: "sqlite", database: ":memory:", entities: Object.values(Models).filter((x) => x.constructor.name == "Function" && shouldIncludeEntity(x.name)), - synchronize: true, + synchronize: true }); await db.initialize(); console.log("Initialized database"); |