Skip to content

Commit

Permalink
Favor 'this' over 'exports'
Browse files Browse the repository at this point in the history
  • Loading branch information
fictorial committed Nov 3, 2009
1 parent 2aba4a7 commit cc142a3
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 1 addition & 1 deletion redis.js
Expand Up @@ -60,7 +60,7 @@ function Client(port, host) {
// Creates a client and connects to the given host:port, then calls a given
// callback function (if any).

exports.create_client = function(callback, port, host) {
this.create_client = function(callback, port, host) {
var client = new Client(port, host);
client.with_connection(callback);
return client;
Expand Down
2 changes: 0 additions & 2 deletions test.js
Expand Up @@ -20,12 +20,10 @@ var pending_callbacks = 0;

function expect_callback() {
pending_callbacks++;
sys.debug("pending_callbacks = " + pending_callbacks);
}

function was_called_back() {
pending_callbacks--;
sys.debug("pending_callbacks = " + pending_callbacks);
}

function expect_true_reply() {
Expand Down

0 comments on commit cc142a3

Please sign in to comment.