redis-rb icon indicating copy to clipboard operation
redis-rb copied to clipboard

HSET error when value to store is empty

Open jppsantana opened this issue 1 year ago • 1 comments

Currently calling the hset method with an empty like value results in the following error:

Redis::CommandError: ERR wrong number of arguments for 'hset' command

Examples:

empty_redis_1

empty_redis_2

Is there any chance this can crash gracefully? Or any thoughts about the best way to handle this without being explicit checking empty values before calling hset? Thanks!

jppsantana avatar Sep 04 '24 22:09 jppsantana

It would be easy to do nothing if the argument is empty yes.

byroot avatar Sep 05 '24 06:09 byroot