Skip to content

Commit 14f7695

Browse files
authored
docs: Remove unnecessary await on pool.prototype.release (denodrivers#384)
1 parent 35cb0ec commit 14f7695

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pool.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ import { DeferredAccessStack } from "./utils/deferred.ts";
4444
* // Connection is created here, will be available from now on
4545
* const client_1 = await pool.connect();
4646
* await client_1.queryArray`SELECT 1`;
47-
* await client_1.release();
47+
* client_1.release();
4848
*
4949
* // Same connection as before, will be reused instead of starting a new one
5050
* const client_2 = await pool.connect();
@@ -53,8 +53,8 @@ import { DeferredAccessStack } from "./utils/deferred.ts";
5353
* // New connection, since previous one is still in use
5454
* // There will be two open connections available from now on
5555
* const client_3 = await pool.connect();
56-
* await client_2.release();
57-
* await client_3.release();
56+
* client_2.release();
57+
* client_3.release();
5858
* ```
5959
*/
6060
export class Pool {
@@ -157,7 +157,7 @@ export class Pool {
157157
* await pool.end();
158158
* const client = await pool.connect();
159159
* await client.queryArray`SELECT 1`; // Works!
160-
* await client.release();
160+
* client.release();
161161
* ```
162162
*/
163163
async end(): Promise<void> {

0 commit comments

Comments
 (0)