rename enum option

This commit is contained in:
yggverse 2024-11-30 04:35:02 +02:00
parent 653960c1ab
commit 1dfaf68267
2 changed files with 4 additions and 4 deletions

View file

@ -23,7 +23,7 @@ impl Connection {
server_identity: Option<NetworkAddress>,
) -> Result<Self, Error> {
if socket_connection.is_closed() {
return Err(Error::SocketConnectionClosed);
return Err(Error::Closed);
}
Ok(Self {
@ -118,7 +118,7 @@ pub fn new_tls_client_connection(
server_identity: Option<&NetworkAddress>,
) -> Result<TlsClientConnection, Error> {
if socket_connection.is_closed() {
return Err(Error::SocketConnectionClosed);
return Err(Error::Closed);
}
// https://geminiprotocol.net/docs/protocol-specification.gmi#the-use-of-tls