if op == "in" {
if rhs, ok := filter[2].([]interface{}); ok {
for _, i := range rhs {
- if u, ok := i.(string); ok {
+ if u, ok := i.(string); ok && len(u) == 27 {
*clusterId = u[0:5]
queryClusters[u[0:5]] = append(queryClusters[u[0:5]], u)
expectCount += 1
}
}
} else if op == "=" {
- if u, ok := filter[2].(string); ok {
+ if u, ok := filter[2].(string); ok && len(u) == 27 {
*clusterId = u[0:5]
queryClusters[u[0:5]] = append(queryClusters[u[0:5]], u)
expectCount += 1
return
}
+ var uuid string
+ if len(m[1]) > 0 {
+ // trim leading slash
+ uuid = m[1][1:]
+ }
for _, d := range h.delegates {
- if d(h, effectiveMethod, &clusterId, m[1], m[3], w, req) {
+ if d(h, effectiveMethod, &clusterId, uuid, m[3], w, req) {
return
}
}