We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b241927 commit 2eb1d51Copy full SHA for 2eb1d51
lib/postgres.js
@@ -1,14 +1,10 @@
1
import {json} from "micro";
2
import {Pool} from "pg";
3
-import {parse} from "url";
4
import QueryStream from "pg-query-stream";
5
import JSONStream from "JSONStream";
6
7
export default url => {
8
- const {
9
- query: {sslmode}
10
- } = parse(url, true);
11
- const pool = new Pool({connectionString: url, ssl: !!sslmode});
+ const pool = new Pool({connectionString: url});
12
13
return async function query(req, res) {
14
const {sql, params} = await json(req);
0 commit comments