mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
allow using targetOrgId parameter to set organisation ID for a request (#41561)
This commit is contained in:
@@ -105,6 +105,10 @@ func (h *ContextHandler) Middleware(mContext *web.Context) {
|
||||
}
|
||||
}
|
||||
|
||||
if targetOrgId := reqContext.QueryInt64("targetOrgId"); targetOrgId != 0 {
|
||||
orgID = targetOrgId
|
||||
}
|
||||
|
||||
// the order in which these are tested are important
|
||||
// look for api key in Authorization header first
|
||||
// then init session and look for userId in session
|
||||
|
||||
Reference in New Issue
Block a user