This reverts commit 3ea75332e7.
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
3a13987ee1
Коммит
e0efdd708b
@@ -407,17 +407,6 @@ func (c *Context) RequirePostId() *Context {
|
||||
return c
|
||||
}
|
||||
|
||||
func (c *Context) RequirePolicyId() *Context {
|
||||
if c.Err != nil {
|
||||
return c
|
||||
}
|
||||
|
||||
if !model.IsValidId(c.Params.PolicyId) {
|
||||
c.SetInvalidUrlParam("policy_id")
|
||||
}
|
||||
return c
|
||||
}
|
||||
|
||||
func (c *Context) RequireAppId() *Context {
|
||||
if c.Err != nil {
|
||||
return c
|
||||
|
||||
@@ -32,7 +32,6 @@ type Params struct {
|
||||
Timestamp int64
|
||||
ChannelId string
|
||||
PostId string
|
||||
PolicyId string
|
||||
FileId string
|
||||
Filename string
|
||||
UploadId string
|
||||
@@ -85,7 +84,6 @@ type Params struct {
|
||||
CategoryId string
|
||||
WarnMetricId string
|
||||
ExportName string
|
||||
ExcludePolicyConstrained bool
|
||||
|
||||
// Cloud
|
||||
InvoiceId string
|
||||
@@ -131,10 +129,6 @@ func ParamsFromRequest(r *http.Request) *Params {
|
||||
params.PostId = val
|
||||
}
|
||||
|
||||
if val, ok := props["policy_id"]; ok {
|
||||
params.PolicyId = val
|
||||
}
|
||||
|
||||
if val, ok := props["file_id"]; ok {
|
||||
params.FileId = val
|
||||
}
|
||||
@@ -357,9 +351,5 @@ func ParamsFromRequest(r *http.Request) *Params {
|
||||
params.ExportName = val
|
||||
}
|
||||
|
||||
if val, err := strconv.ParseBool(query.Get("exclude_policy_constrained")); err == nil {
|
||||
params.ExcludePolicyConstrained = val
|
||||
}
|
||||
|
||||
return params
|
||||
}
|
||||
|
||||
Ссылка в новой задаче
Block a user