Skip to content

Commit

Permalink
Correct affiliations handling in public/seminar.
Browse files Browse the repository at this point in the history
  • Loading branch information
robol committed Nov 21, 2023
1 parent 7e85851 commit 5b1b7fc
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions server/controllers/public/seminar.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ async function seminarQuery(req) {
const seminar_id = req.params.id
const pipeline = [
{ $match: {
_id: new ObjectId(seminar_id),
_id: ObjectId(seminar_id),
}},
{ $lookup: {
from: 'people',
Expand All @@ -21,8 +21,8 @@ async function seminarQuery(req) {
from: 'institutions',
localField: 'speaker.affiliations',
foreignField: '_id',
as: 'affiliations'
}},
as: 'speaker.affiliations'
}},
{$lookup: {
from: 'seminarcategories',
localField: 'category',
Expand Down Expand Up @@ -67,7 +67,7 @@ async function seminarQuery(req) {
_id: 1,
firstName: 1,
lastName: 1,
affiliations: 1,
affiliations: 1
},
abstract: 1,
}}
Expand Down

0 comments on commit 5b1b7fc

Please sign in to comment.