Commit 4c85c77d authored by NataliaTepluhina's avatar NataliaTepluhina Committed by Natalia Tepluhina

Changed check to optional chaining

parent 198f25df
......@@ -113,9 +113,7 @@ export default {
update(data) {
// TODO Remove null filter (BE fix required)
// https://gitlab.com/gitlab-org/gitlab/-/issues/329750
const users = data.workspace?.users?.nodes.filter((x) => x).map(({ user }) => user) || [];
// User field is nullable and we only want to display non-null users
return users.filter((u) => u);
return data.workspace?.users?.nodes.filter((x) => x?.user).map(({ user }) => user) || [];
},
debounce: ASSIGNEES_DEBOUNCE_DELAY,
error({ graphQLErrors }) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment