1
0
mirror of https://github.com/redis/node-redis.git synced 2025-08-06 02:15:48 +03:00

chore: refactor main code base into smaller parts

This commit is contained in:
Ruben Bridgewater
2017-05-26 23:34:28 +02:00
parent 3065e2e7be
commit 1f179ef791
7 changed files with 322 additions and 291 deletions

View File

@@ -1,12 +1,15 @@
'use strict'
const index = require('../')
var index
function lazyIndex () {
return index || require('../')
}
/**
* @description Print a debug statement if in debug mode
*/
function debug () {
if (index.debugMode) {
if (lazyIndex().debugMode) {
console.error.apply(null, arguments)
}
}