Skip to content

Commit

Permalink
Cyberleague: [premieroctet#116] Fix one field test in related_users c…
Browse files Browse the repository at this point in the history
…omputing
  • Loading branch information
Bastien-Wappizy committed Sep 13, 2024
1 parent df75712 commit 16a4e0e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion backend/web/server/plugins/cyberleague/related.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const getRelated = (model) => {
let res = []

const sameUserFunction = lodash.groupBy(users, (u) => u.function)[data.function]
const sameFunLength = sameUserFunction.length || 0
const sameFunLength = sameUserFunction?.length || 0

//if not enough related with same function, need to add users with same company size
if (sameFunLength <10) {
Expand Down

0 comments on commit 16a4e0e

Please sign in to comment.