Skip to content
Snippets Groups Projects
Commit 6cdaccf5 authored by Sebastian Mihalache's avatar Sebastian Mihalache :hammer_pick:
Browse files

fix(collection-service): remove he id check from canHEMakeRecommendation

parent 13f106ac
No related branches found
No related tags found
3 merge requests!176Sprint 24,!171Sprint 24,!165Hin 845 revoke and assign he
...@@ -147,17 +147,19 @@ class Collection { ...@@ -147,17 +147,19 @@ class Collection {
[], [],
) )
const lastRecommendationByHE = findLast( const lastEditorRecommendation = findLast(
previousVersionRecommendations, previousVersionRecommendations,
recommendation => recommendation =>
recommendation.userId === this.collection.handlingEditor.id &&
recommendation.recommendationType === 'editorRecommendation', recommendation.recommendationType === 'editorRecommendation',
) )
if (lastRecommendationByHE.recommendation === 'minor') {
if (lastEditorRecommendation.recommendation === 'minor') {
return this.hasAtLeastOneReviewReport(fragments) return this.hasAtLeastOneReviewReport(fragments)
} else if (lastRecommendationByHE.recommendation === 'major') { } else if (lastEditorRecommendation.recommendation === 'major') {
return fragmentHelper.hasReviewReport() return fragmentHelper.hasReviewReport()
} }
return false
} }
async getAllFragments({ FragmentModel }) { async getAllFragments({ FragmentModel }) {
......
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