MCPcopy Create free account
hub / github.com/ByteStorage/FlyDB / stringIncrByFloat

Function stringIncrByFloat

cmd/client/string.go:148–162  ·  view source on GitHub ↗
(c *grumble.Context)

Source from the content-addressed store, hash-verified

146}
147
148func stringIncrByFloat(c *grumble.Context) error {
149 key := c.Args.String("key")
150 amount := c.Args.Float64("amount")
151 if key == "" {
152 fmt.Println("key is empty")
153 return nil
154 }
155 err := newClient().IncrByFloat(key, amount)
156 if err != nil {
157 fmt.Println("incrbyfloat operation error: ", err)
158 return err
159 }
160 fmt.Println("IncrByFloat operation success")
161 return nil
162}
163
164func stringDecr(c *grumble.Context) error {
165 key := c.Args.String("key")

Callers

nothing calls this directly

Calls 3

newClientFunction · 0.85
IncrByFloatMethod · 0.65
StringMethod · 0.45

Tested by

no test coverage detected