Skip to content

Commit 399d24a

Browse files
committed
PostgreSQLQuery update
1 parent 9896172 commit 399d24a

File tree

3 files changed

+300
-92
lines changed

3 files changed

+300
-92
lines changed

Sources/PostgreSQL/Connection/PostgreSQLConnection+Query.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ extension PostgreSQLConnection {
4646
/// - returns: A future that signals query completion.
4747
public func query(_ query: PostgreSQLQuery, resultFormat: PostgreSQLResultFormat = .binary, onRow: @escaping ([PostgreSQLColumn: PostgreSQLData]) throws -> ()) -> Future<Void> {
4848
var binds: [PostgreSQLData] = []
49-
let sql = query.serialize(binds: &binds)
49+
let sql = query.serialize(&binds)
5050
return operation {
5151
do {
5252
return try self._query(sql, binds, resultFormat: resultFormat, onRow: onRow)

Sources/PostgreSQL/Connection/PostgreSQLConnection+SimpleQuery.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ extension PostgreSQLConnection {
2424

2525
public func simpleQuery(_ query: PostgreSQLQuery, onRow: @escaping ([PostgreSQLColumn: PostgreSQLData]) throws -> ()) -> Future<Void> {
2626
var binds: [PostgreSQLData] = []
27-
let sql = query.serialize(binds: &binds)
27+
let sql = query.serialize(&binds)
2828
assert(binds.count == 0, "Binds not allowed in simpleQuery(...). Use query(...) instead.")
2929
return operation { self._simpleQuery(sql, onRow: onRow) }
3030
}

0 commit comments

Comments
 (0)