Skip to content

Commit 92d84a4

Browse files
authored
Merge pull request #107 from boolean-uk/Fredag
Fredag ok -johan
2 parents 7616bc2 + 53ed6e0 commit 92d84a4

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

exercise.wwwapi/Endpoints/UserEndpoints.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,8 +340,7 @@ public static async Task<IResult> UpdateUser(IRepository<User> userRepository, i
340340
{
341341
// Only teacher can edit protected fields
342342
var authorized = AuthorizeTeacher(claimsPrinciple);
343-
if (!authorized && (request is not null
344-
|| request.Role is not null))
343+
if (!authorized && (request.Role is not null))
345344
{
346345
return Results.Unauthorized();
347346
}

0 commit comments

Comments
 (0)