(m uhaha.Machine, args []string)
| 270 | } |
| 271 | |
| 272 | func cmdZREM(m uhaha.Machine, args []string) (interface{}, error) { |
| 273 | if len(args) < 3 { |
| 274 | return nil, uhaha.ErrWrongNumArgs |
| 275 | } |
| 276 | |
| 277 | members := make([][]byte, len(args)-2) |
| 278 | |
| 279 | for i := 2; i < len(args); i++ { |
| 280 | members[i-2] = []byte(args[i]) |
| 281 | } |
| 282 | |
| 283 | n, err := ldb.ZRem([]byte(args[1]), members...) |
| 284 | |
| 285 | if err != nil { |
| 286 | return nil, err |
| 287 | } |
| 288 | |
| 289 | return redcon.SimpleInt(n), nil |
| 290 | } |
| 291 | |
| 292 | func cmdZADD(m uhaha.Machine, args []string) (interface{}, error) { |
| 293 | if len(args) < 3 { |
nothing calls this directly
no outgoing calls
no test coverage detected