-
Notifications
You must be signed in to change notification settings - Fork 319
Closed
Description
Hi, thanks for all the great work. I noticed the default value for publications was always being used. I managed to get it working by editing source and adding the following assignment on the options copy:
return Object.assign({
host : Array.isArray(host) ? host : host.split(',').map(x => x.split(':')[0]),
port : Array.isArray(port) ? port : host.split(',').map(x => parseInt(x.split(':')[1] || port)),
path : o.path || host.indexOf('/') > -1 && host + '/.s.PGSQL.' + port,
database : o.database || o.db || (url.pathname || '').slice(1) || env.PGDATABASE || user,
user : user,
pass : o.pass || o.password || url.password || env.PGPASSWORD || '',
max : o.max || query.get('max') || 10,
types : o.types || {},
ssl : o.ssl || parseSSL(query.get('sslmode') || query.get('ssl')) || false,
idle_timeout : o.idle_timeout || query.get('idle_timeout') || env.PGIDLE_TIMEOUT || warn(o.timeout),
connect_timeout : o.connect_timeout || query.get('connect_timeout') || env.PGCONNECT_TIMEOUT || 30,
max_lifetime : o.max_lifetime || url.max_lifetime || max_lifetime,
max_pipeline : o.max_pipeline || url.max_pipeline || 100,
backoff : o.backoff || url.backoff || backoff,
keep_alive : o.keep_alive || url.keep_alive || 60,
prepare : 'prepare' in o ? o.prepare : 'no_prepare' in o ? !o.no_prepare : true,
onnotice : o.onnotice,
onnotify : o.onnotify,
onclose : o.onclose,
onparameter : o.onparameter,
+++
publications : o.publications,
+++
transform : parseTransform(o.transform || {}),
connection : Object.assign({ application_name: 'postgres.js' }, o.connection),
target_session_attrs: tsa(o, url, env),
debug : o.debug,
fetch_types : 'fetch_types' in o ? o.fetch_types : true,
parameters : {},
shared : { retries: 0, typeArrayMap: {} }
},
mergeUserTypes(o.types)
)
Edit: I think I see a slightly different source view when I'm debugging through node_modules. It's at this spot.
Metadata
Metadata
Assignees
Labels
No labels