1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-07 13:22:56 +03:00

chore: refactor codebase to promises

This commit is contained in:
Ruben Bridgewater
2017-05-19 06:14:29 +02:00
parent b2613b2270
commit 6be5575c5b
85 changed files with 2081 additions and 3690 deletions

View File

@@ -6,9 +6,9 @@ const redis = require('../../index')
const client = redis.createClient()
// Both error cases would normally return bad stack traces
client.set('foo', (err, res) => {
client.set('foo').catch((err) => {
assert(/good-traces.js:9:8/.test(err.stack))
client.set('foo', 'bar', (err, res) => {
client.set('foo', 'bar').catch((err) => {
assert(/good-traces.js:11:10/.test(err.stack))
client.quit(() => {
process.exit(0)