mirror of https://github.com/shunfei/cronsun
Baned backslash in group name
parent
3fe62f5fb0
commit
0e3745c384
|
@ -120,7 +120,7 @@ func (c *Client) DelLock(key string) error {
|
|||
}
|
||||
|
||||
func IsValidAsKeyPath(s string) bool {
|
||||
return strings.IndexByte(s, '/') == -1
|
||||
return strings.IndexAny(s, "/\\") == -1
|
||||
}
|
||||
|
||||
// etcdTimeoutContext return better error info
|
||||
|
|
|
@ -8,8 +8,8 @@ var (
|
|||
|
||||
ErrEmptyJobName = errors.New("Name of job is empty.")
|
||||
ErrEmptyJobCommand = errors.New("Command of job is empty.")
|
||||
ErrIllegalJobId = errors.New("Invalid id that includes illegal characters such as '/'.")
|
||||
ErrIllegalJobGroupName = errors.New("Invalid job group name that includes illegal characters such as '/'.")
|
||||
ErrIllegalJobId = errors.New("Invalid id that includes illegal characters such as '/' '\\'.")
|
||||
ErrIllegalJobGroupName = errors.New("Invalid job group name that includes illegal characters such as '/' '\\'.")
|
||||
|
||||
ErrEmptyNodeGroupName = errors.New("Name of node group is empty.")
|
||||
ErrIllegalNodeGroupId = errors.New("Invalid node group id that includes illegal characters such as '/'.")
|
||||
|
|
Loading…
Reference in New Issue