MM-64531: [Shared Channels] Users on different remote servers should not communicate unless the remotes have established secure connection. (#30985) (#33434)
Automatic Merge
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
3a6aeee57e
Коммит
07a34f02b6
@@ -300,6 +300,17 @@ func (c *Context) RequireUserId() *Context {
|
||||
return c
|
||||
}
|
||||
|
||||
func (c *Context) RequireOtherUserId() *Context {
|
||||
if c.Err != nil {
|
||||
return c
|
||||
}
|
||||
|
||||
if !model.IsValidId(c.Params.OtherUserId) {
|
||||
c.SetInvalidURLParam("other_user_id")
|
||||
}
|
||||
return c
|
||||
}
|
||||
|
||||
func (c *Context) RequireTeamId() *Context {
|
||||
if c.Err != nil {
|
||||
return c
|
||||
|
||||
@@ -26,6 +26,7 @@ const (
|
||||
|
||||
type Params struct {
|
||||
UserId string
|
||||
OtherUserId string
|
||||
TeamId string
|
||||
InviteId string
|
||||
TokenId string
|
||||
@@ -129,6 +130,7 @@ func ParamsFromRequest(r *http.Request) *Params {
|
||||
query := r.URL.Query()
|
||||
|
||||
params.UserId = props["user_id"]
|
||||
params.OtherUserId = props["other_user_id"]
|
||||
params.TeamId = props["team_id"]
|
||||
params.CategoryId = props["category_id"]
|
||||
params.InviteId = props["invite_id"]
|
||||
|
||||
Ссылка в новой задаче
Block a user