Commit 068854f8 authored by Marcel Nellesen's avatar Marcel Nellesen
Browse files

Small fix (coscine/issues#1035)

parent ac480532
......@@ -178,7 +178,7 @@ namespace Coscine.Database.Models
var projectId = new ProjectResourceModel().GetProjectForResource(resource.Id);
IEnumerable<string> allowedAccessLabels = allowedAccess.Select(x => x.ToLower().Trim()).ToList();
return DatabaseConnection.ConnectToDatabase((db) => (from relation in db.ProjectRoles
where relation.ProjectId != projectId
where relation.ProjectId == projectId
&& relation.User.Id == user.Id
&& allowedAccessLabels.Contains(relation.Role.DisplayName.ToLower())
select relation).Any());
Supports Markdown
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