Skip to content

Commit 1d3cc43

Browse files
committed
Fixing the site lookup to not include removed sites.
1 parent 959b3e9 commit 1d3cc43

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

eFormAPI/Plugins/Workflow.Pn/Workflow.Pn/Services/WorkflowCasesService/WorkflowCasesService.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,9 @@ public async Task<OperationResult> UpdateWorkflowCase(WorkflowCasesUpdateModel m
424424
Site createdBySite = await sdkDbContext.Sites.SingleOrDefaultAsync(x => x.Id == _case.SiteId);
425425
if (!string.IsNullOrEmpty(workflowCase.SolvedBy))
426426
{
427-
Site site = await sdkDbContext.Sites.SingleOrDefaultAsync(x =>
427+
Site site = await sdkDbContext.Sites
428+
.Where(x => x.WorkflowState != Constants.WorkflowStates.Removed)
429+
.SingleOrDefaultAsync(x =>
428430
x.Name == workflowCase.SolvedBy);
429431

430432
if (workflowCase.SolvedBy != createdBySite.Name)

0 commit comments

Comments
 (0)