Skip to content

Commit

Permalink
fmt check fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ljudevit committed Apr 16, 2024
1 parent a2f5797 commit 4ea2bb7
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
4 changes: 3 additions & 1 deletion src/api/query.rs
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,9 @@ where
}

client
.send(PgWireBackendMessage::CommandComplete(tag.with_rows(rows).into()))
.send(PgWireBackendMessage::CommandComplete(
tag.with_rows(rows).into(),
))
.await?;

Ok(())
Expand Down
6 changes: 5 additions & 1 deletion src/api/results.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,11 @@ pub struct QueryResponse<'a> {

impl<'a> QueryResponse<'a> {
/// Create `QueryResponse` from column schemas and stream of data row
pub fn new<S>(command_tag: &str, field_defs: Arc<Vec<FieldInfo>>, row_stream: S) -> QueryResponse<'a>
pub fn new<S>(
command_tag: &str,
field_defs: Arc<Vec<FieldInfo>>,
row_stream: S,
) -> QueryResponse<'a>
where
S: Stream<Item = PgWireResult<DataRow>> + Send + Unpin + 'a,
{
Expand Down
6 changes: 5 additions & 1 deletion tests-integration/test-server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,11 @@ impl ExtendedQueryHandler for DummyDatabase {
encoder.finish()
});

Ok(Response::Query(QueryResponse::new("SELECT", schema, data_row_stream)))
Ok(Response::Query(QueryResponse::new(
"SELECT",
schema,
data_row_stream,
)))
} else {
Ok(Response::Execution(Tag::new("OK").with_rows(1)))
}
Expand Down

0 comments on commit 4ea2bb7

Please sign in to comment.