Skip to content

Commit 1bf7c74

Browse files
damienmoulardClement-Roque
authored andcommitted
add authorization checks
1 parent faf2752 commit 1bf7c74

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: Zenergy/Zenergy/Controllers/ApiControllers/usersController.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,14 @@ public usersController()
2626
}
2727

2828
// GET: api/users
29-
3029
[Authorize(Roles = "Admin")]
3130
public IQueryable<user> Getuser()
3231
{
3332
return db.user;
3433
}
3534

3635
// GET: api/users/5
36+
[Authorize(Roles = "Admin")]
3737
[ResponseType(typeof(user))]
3838
public async Task<IHttpActionResult> Getuser(int id)
3939
{

0 commit comments

Comments
 (0)