Skip to content

Commit

Permalink
feat: log notice message
Browse files Browse the repository at this point in the history
  • Loading branch information
gajus committed Jul 29, 2018
1 parent 70b01fe commit 08e4173
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/index.js
Expand Up @@ -546,6 +546,12 @@ export const createConnection = async (

const connection = await pool.connect();

connection.on('notice', (notice) => {
log.info({
notice
}, 'notice message');
});

let ended = false;

const bindConnection = {
Expand Down Expand Up @@ -625,6 +631,12 @@ export const createPool = (
const connect = async () => {
const connection = await pool.connect();

connection.on('notice', (notice) => {
log.info({
notice
}, 'notice message');
});

const bindConnection = {
any: mapTaggedTemplateLiteralInvocation(any.bind(null, connection, clientConfiguration)),
anyFirst: mapTaggedTemplateLiteralInvocation(anyFirst.bind(null, connection, clientConfiguration)),
Expand Down

0 comments on commit 08e4173

Please sign in to comment.