Skip to content

Commit 84ace46

Browse files
committed
Merge pull request #582 from rhoot/patch-1
Updated README.md for d5753f8
2 parents 7ab0195 + 03dcbb3 commit 84ace46

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Readme.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ pool.on('connection', function(err, connection) {
225225
});
226226
```
227227

228-
When you are done with a connection, just call `connection.end()` and the
228+
When you are done with a connection, just call `connection.release()` and the
229229
connection will return to the pool, ready to be used again by someone else.
230230

231231
```js
@@ -236,7 +236,7 @@ pool.getConnection(function(err, connection) {
236236
// Use the connection
237237
connection.query( 'SELECT something FROM sometable', function(err, rows) {
238238
// And done with the connection.
239-
connection.end();
239+
connection.release();
240240

241241
// Don't use the connection here, it has been returned to the pool.
242242
});

0 commit comments

Comments
 (0)