Open
Description
Redis docs for the EXPIRE command state that it returns an "Integer reply"
in node-redis the response is transformed into a boolean.
// NOTE: r - instance of redis client
> r.set('aaa','888').then(console.log)
Promise {
<pending>,
[Symbol(async_id_symbol)]: 2924,
[Symbol(trigger_async_id_symbol)]: 2920
}
> OK
> r.get('aaa').then(console.log)
Promise {
<pending>,
[Symbol(async_id_symbol)]: 2545,
[Symbol(trigger_async_id_symbol)]: 2541
}
> 888
> r.expire('aaa', -11).then(console.log)
Promise {
<pending>,
[Symbol(async_id_symbol)]: 2718,
[Symbol(trigger_async_id_symbol)]: 2714
}
> true // <======= returns bool
Environment:
- Node.js Version: v16.18.1
- Redis Server Version: redis_version:6.2.6
- Node Redis Version: redis@4.5.1
- Platform: debian 10 buster (docker)