Files

14 lines
459 B
C#
Raw Permalink Normal View History

2026-08-19 23:25:08 +07:00
using mws.backend.dotnet.application.Common;
using mws.backend.dotnet.domain.Projects;
2026-08-19 23:25:08 +07:00
namespace mws.backend.dotnet.application.Projects;
internal static class ProjectAccess
{
public static async Task<Project> GetForUserOrThrowAsync(IUnitOfWork uow, Guid userId, Guid projectId, CancellationToken ct)
{
return await uow.Projects.GetForUserAsync(userId, projectId, ct)
?? throw new NotFoundException("Project not found");
}
}