Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Commit d6eb054

Browse files
author
Jakub Wieczorek
committed
Fix the build after the rebase.
1 parent 4e95c82 commit d6eb054

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

tokio-postgres/src/prepare.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ pub async fn prepare(
5555
if let Some(row_description) = row_description {
5656
let mut it = row_description.fields();
5757
while let Some(field) = it.next().map_err(Error::parse)? {
58-
let type_ = get_type(client, field.type_oid()).await?;
58+
let type_ = get_type(field.type_oid());
5959
let column = Column {
6060
name: field.name().to_string(),
6161
table_oid: Some(field.table_oid()).filter(|n| *n != 0),

tokio-postgres/src/query.rs

+7-1
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,13 @@ fn make_statement(
239239

240240
while let Some(field) = it.next().map_err(Error::parse)? {
241241
let type_ = crate::prepare::get_type(field.type_oid());
242-
let column = Column::new(field.name().to_string(), type_, field);
242+
let column = Column {
243+
name: field.name().to_string(),
244+
table_oid: Some(field.table_oid()).filter(|n| *n != 0),
245+
column_id: Some(field.column_id()).filter(|n| *n != 0),
246+
r#type: type_,
247+
};
248+
243249
columns.push(column);
244250
}
245251
}

tokio-postgres/src/statement.rs

+2-8
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,8 @@ use crate::client::InnerClient;
22
use crate::codec::FrontendMessage;
33
use crate::connection::RequestMessages;
44
use crate::types::Type;
5-
use postgres_protocol::{
6-
message::{backend::Field, frontend},
7-
Oid,
8-
};
9-
use std::{
10-
fmt,
11-
sync::{Arc, Weak},
12-
};
5+
use postgres_protocol::message::frontend;
6+
use std::sync::{Arc, Weak};
137

148
#[derive(Debug)]
159
enum StatementInner {

0 commit comments

Comments
 (0)