Skip to content

Commit

Permalink
Updated Get project users action
Browse files Browse the repository at this point in the history
  • Loading branch information
vitalii-bezuhlyi committed Feb 9, 2024
1 parent f8a9893 commit 325d923
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Apps.XTM/Actions/ProjectActions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,16 @@ public async Task<ProjectUsersResponse> GetProjectUsers([ActionParameter] Projec
ProjectCreator = await GetUserById(projectUsers.ProjectCreator.UserId)
};

if (projectUsersResponse.ProjectManager is null)
{
throw new Exception("Project manager not found");
}

if (projectUsersResponse.ProjectCreator is null)
{
throw new Exception("Project creator not found");
}

foreach (var linguist in projectUsers.Linguists)
{
projectUsersResponse.Linguists.Add(await GetUserById(linguist.UserId));
Expand Down

0 comments on commit 325d923

Please sign in to comment.