Skip to content

Commit

Permalink
removed unnecessary connectionPool.release()
Browse files Browse the repository at this point in the history
  • Loading branch information
ben-page committed Oct 29, 2014
1 parent a3e4383 commit d7567ca
Showing 4 changed files with 3 additions and 14 deletions.
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -48,10 +48,6 @@ It is then available to be reused.
* `error` {Error Object}
* `connection` {Object} A [Connection](http://pekim.github.com/tedious/api-connection.html)

### connectionPool.release(connection)

* `connection` {Object} A [Connection](http://pekim.github.com/tedious/api-connection.html)

### connectionPool.drain(callback)

* `callback` {Function} Callback function
4 changes: 0 additions & 4 deletions lib/connection-pool.js
Original file line number Diff line number Diff line change
@@ -34,10 +34,6 @@ ConnectionPool.prototype.acquire = function (callback) {
return this.pool.acquire(callback);
};

ConnectionPool.prototype.release = function (connection) {
return this.pool.release(connection);
};

ConnectionPool.prototype.drain = function (callback) {
var self = this;

2 changes: 1 addition & 1 deletion lib/pooled-connection.js
Original file line number Diff line number Diff line change
@@ -17,7 +17,7 @@ function PooledConnection(connectionPool, config) {
PooledConnection.prototype = Object.create(Connection.prototype);

PooledConnection.prototype.release = function () {
this.connectionPool.release(this);
this.connectionPool.pool.release(this);
};

module.exports = PooledConnection;
7 changes: 2 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "tedious-connection-pool",
"version": "0.2.1",
"version": "0.2.2",
"description": "Connection Pool for tedious.",
"main": "lib/connection-pool.js",
"dependencies": {
@@ -59,8 +59,5 @@
"bugs": {
"url": "https://github.com/pekim/tedious-connection-pool/issues"
},
"homepage": "https://github.com/pekim/tedious-connection-pool",
"_id": "tedious-connection-pool@0.1.3",
"_shasum": "1be288bfd2da593b2111ec02efed508f95f1772b",
"_from": "..\\tedious-connection-pool"
"homepage": "https://github.com/pekim/tedious-connection-pool"
}

0 comments on commit d7567ca

Please sign in to comment.