Why does redis return boolean for HGET in lua script?

Viewed 306

This is my eval command

eval "local b = redis.call('hget', 'foo', 'baz'); if (type(b) == 'boolean') then return 'boolean' else return 'not a boolean' end" 0 "hello"

This returns boolean. But if I return the value of b I get (nil). What is happening here?

1 Answers
Related