Commit e274947b authored by Kushal Pandya's avatar Kushal Pandya

Merge branch 'Remove-findLabel-logic-from-issues-model' into 'master'

Remove findLabel logic from issue model

See merge request gitlab-org/gitlab!32239
parents ef9b1a34 b8b2591e
...@@ -36,7 +36,7 @@ class ListIssue { ...@@ -36,7 +36,7 @@ class ListIssue {
} }
findLabel(findLabel) { findLabel(findLabel) {
return this.labels.find(label => label.id === findLabel.id); return boardsStore.findIssueLabel(this, findLabel);
} }
removeLabel(removeLabel) { removeLabel(removeLabel) {
......
...@@ -133,6 +133,10 @@ const boardsStore = { ...@@ -133,6 +133,10 @@ const boardsStore = {
path: '', path: '',
}); });
}, },
findIssueLabel(issue, findLabel) {
return issue.labels.find(label => label.id === findLabel.id);
},
addListIssue(list, issue, listFrom, newIndex) { addListIssue(list, issue, listFrom, newIndex) {
let moveBeforeId = null; let moveBeforeId = null;
let moveAfterId = null; let moveAfterId = null;
......
---
title: Remove findLabel logic from issue model
merge_request: 32239
author: nuwe1
type: other
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