Skip to content

Commit c80fefe

Browse files
author
loay
committed
Update getDefaultSchema
1 parent d0bf4bb commit c80fefe

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

lib/discovery.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,10 @@ function mixinDiscovery(PostgreSQL) {
331331
};
332332

333333
PostgreSQL.prototype.getDefaultSchema = function() {
334-
return '';
334+
if (this.dataSource && this.dataSource.settings &&
335+
this.dataSource.settings.database) {
336+
return this.dataSource.settings.database;
337+
}
338+
return undefined;
335339
};
336340
}

0 commit comments

Comments
 (0)