mirror of
https://github.com/grafana/grafana.git
synced 2025-07-29 05:52:22 +08:00
add context to getsignedinUser calls (#35963)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
This commit is contained in:
@ -165,7 +165,7 @@ func (hs *HTTPServer) PostSyncUserWithLDAP(c *models.ReqContext) response.Respon
|
||||
|
||||
query := models.GetUserByIdQuery{Id: userId}
|
||||
|
||||
if err := bus.Dispatch(&query); err != nil { // validate the userId exists
|
||||
if err := bus.DispatchCtx(c.Req.Context(), &query); err != nil { // validate the userId exists
|
||||
if errors.Is(err, models.ErrUserNotFound) {
|
||||
return response.Error(404, models.ErrUserNotFound.Error(), nil)
|
||||
}
|
||||
|
Reference in New Issue
Block a user