Fix failing tests in Task Resolution (#15634)

This commit is contained in:
Sriharsha Chintalapani 2024-03-20 13:49:03 -07:00 committed by GitHub
parent b304cbf55f
commit a6deffdd7c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -805,7 +805,9 @@ public class FeedRepository {
// Allow if user created the task to close task (and not resolve task)
EntityReference owner = Entity.getOwner(aboutRef);
List<EntityReference> assignees = thread.getTask().getAssignees();
if (owner.getName().equals(userName) || closeTask && thread.getCreatedBy().equals(userName)) {
if (owner != null
&& (owner.getName().equals(userName)
|| closeTask && thread.getCreatedBy().equals(userName))) {
return;
}