From 1bf671fdfe9eaf0fcefc819e982264c2eea695e1 Mon Sep 17 00:00:00 2001 From: Ayush Mukherjee Date: Sun, 14 Mar 2021 06:05:54 +0530 Subject: [PATCH] model issue --- src/ws/crud.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/ws/crud.js b/src/ws/crud.js index bfc771b..5b71685 100644 --- a/src/ws/crud.js +++ b/src/ws/crud.js @@ -85,10 +85,11 @@ const matchFns = { const streamFns = { getAll: async () => { - return await streams.find().populate('event').populate({ - path: 'matches', - populate: [{ path: 'orange' }, { path: 'blue' }], - }).populate('casters').populate('hosts').exec() + return await streams.find().exec() + // return await streams.find().populate('event').populate({ + // path: 'matches', + // populate: [{ path: 'orange' }, { path: 'blue' }], + // }).populate('casters').populate('hosts').exec() }, getById: async (id) => { return await streams.findById(id).populate('event').populate('matches').populate('casters').populate('hosts').exec()