go-zero icon indicating copy to clipboard operation
go-zero copied to clipboard

Why the signature of the `hmset` function in `redis` use `map[string]string `instead of `map[string]any` type key-value?

Open Suyghur opened this issue 1 year ago • 1 comments
trafficstars

in some case, such as json string:

{
    "aaa": "111",
    "bbb": 222,
    "ccc": 0
}

use Unmarshal to map[string]string will be wrong, the field bbb is empty string in redis

Suyghur avatar Jul 02 '24 12:07 Suyghur

Better to use the same type in the hash key.

kevwan avatar Jul 07 '24 12:07 kevwan

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] avatar Jul 08 '25 02:07 github-actions[bot]

This issue was closed because it has been inactive for 14 days since being marked as stale.

github-actions[bot] avatar Oct 07 '25 02:10 github-actions[bot]