Method: Redis#hsetnx
- Defined in:
- lib/redis.rb
#hsetnx(key, field, value) ⇒ Boolean
Set the value of a hash field, only if the field does not exist.
1329 1330 1331 1332 1333 |
# File 'lib/redis.rb', line 1329 def hsetnx(key, field, value) synchronize do @client.call [:hsetnx, key, field, value], &_boolify end end |