aboutsummaryrefslogtreecommitdiff
path: root/services/votes/votes.class.ts
diff options
context:
space:
mode:
Diffstat (limited to 'services/votes/votes.class.ts')
-rw-r--r--services/votes/votes.class.ts14
1 files changed, 0 insertions, 14 deletions
diff --git a/services/votes/votes.class.ts b/services/votes/votes.class.ts
deleted file mode 100644
index 3220ee7..0000000
--- a/services/votes/votes.class.ts
+++ /dev/null
@@ -1,14 +0,0 @@
-import PollModel from '../../models/polls/poll.model';
-import { PollSchema } from '../../models/polls/poll.schema';
-
-export default class Votes {
- async create(data: any, params: any): Promise<PollSchema | null> {
- const poll = await PollModel.findById(params.route.id);
- if (poll) {
- const updatedPoll = await poll.vote(params.user._id, data.which);
- return updatedPoll.toObject();
- }
- return null;
- }
-}
-