aboutsummaryrefslogtreecommitdiff
path: root/populateDb.ts
diff options
context:
space:
mode:
authoreug-vs <eug-vs@keemail.me>2020-06-21 14:29:59 +0300
committereug-vs <eug-vs@keemail.me>2020-06-21 14:30:55 +0300
commite99b51895afd532a529744396ecae87d47c68503 (patch)
treeb5c1ebc0f364d8e11ddad0f27b57340d45b44bb1 /populateDb.ts
parentf4c4f2d4789880c0cfc956d08aab10b5a93ebcb1 (diff)
downloadwhich-api-e99b51895afd532a529744396ecae87d47c68503.tar.gz
feat: change hooks and install which-types
Diffstat (limited to 'populateDb.ts')
-rw-r--r--populateDb.ts4
1 files changed, 1 insertions, 3 deletions
diff --git a/populateDb.ts b/populateDb.ts
index ae42d86..a666427 100644
--- a/populateDb.ts
+++ b/populateDb.ts
@@ -29,9 +29,7 @@ const names: string[] = [
];
-
const createPoll = (authorId: string, generateImageData:()=> ImageDataSchema): Promise<PollSchema> => {
-
return app.service('polls').create({
contents: {
left: generateImageData(),
@@ -60,7 +58,7 @@ const populate = async () => {
await bluebird.mapSeries(new Array(POLLS_AMOUNT), async () => {
const sampleUser = _.sample(users);
- return createPoll(sampleUser?._id,generateImageData);
+ return createPoll(sampleUser?._id, generateImageData);
});
};