(pool: pg.Pool)
| 257 | } |
| 258 | |
| 259 | function postgresPool(pool: pg.Pool): Pool { |
| 260 | return { |
| 261 | async getConnection(): Promise<Conn> { |
| 262 | const conn = await pool.connect(); |
| 263 | return postgresConn(conn); |
| 264 | }, |
| 265 | end() { |
| 266 | pool.end(); |
| 267 | }, |
| 268 | }; |
| 269 | } |
| 270 | |
| 271 | function postgresConn(conn: pg.PoolClient): Conn { |
| 272 | return { |
no outgoing calls
no test coverage detected