Remove the last non-borrowed string from BeMessage (#1376)

This commit is contained in:
Dmitry Ivanov
2022-03-17 16:46:58 +03:00
committed by GitHub
parent ab124c161b
commit a7544eead5
2 changed files with 3 additions and 3 deletions

View File

@@ -200,7 +200,7 @@ async fn handle_new_user(
client
.write_message_noflush(&Be::AuthenticationOk)?
.write_message_noflush(&BeParameterStatusMessage::encoding())?
.write_message(&Be::NoticeResponse(greeting))
.write_message(&Be::NoticeResponse(&greeting))
.await?;
// Wait for web console response (see `mgmt`)
@@ -208,7 +208,7 @@ async fn handle_new_user(
})
.await?;
client.write_message_noflush(&Be::NoticeResponse("Connecting to database.".into()))?;
client.write_message_noflush(&Be::NoticeResponse("Connecting to database."))?;
Ok(db_info)
}

View File

@@ -425,7 +425,7 @@ pub enum BeMessage<'a> {
ReadyForQuery,
RowDescription(&'a [RowDescriptor<'a>]),
XLogData(XLogDataBody<'a>),
NoticeResponse(String),
NoticeResponse(&'a str),
KeepAlive(WalSndKeepAlive),
}