feat: add impl Debug
This commit is contained in:
parent
e92f0c62a2
commit
6efe51bb15
3 changed files with 4 additions and 1 deletions
|
@ -1,3 +1,4 @@
|
|||
#[derive(Debug)]
|
||||
pub enum LibError {
|
||||
IoError(std::io::Error),
|
||||
InvalidUrlError(InvalidUrl),
|
||||
|
@ -48,6 +49,7 @@ impl From<mime::FromStrError> for LibError {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub enum InvalidUrl {
|
||||
ParseError(url::ParseError),
|
||||
SchemeNotGemini,
|
||||
|
|
|
@ -2,6 +2,7 @@ use crate::{status::Status, LibError};
|
|||
|
||||
type BodyStream = tokio_rustls::client::TlsStream<tokio::net::TcpStream>;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct Response {
|
||||
status: Status,
|
||||
message: String,
|
||||
|
|
|
@ -2,7 +2,7 @@ use crate::error::LibError;
|
|||
|
||||
use num_enum::{IntoPrimitive, TryFromPrimitive};
|
||||
|
||||
#[derive(Clone, Copy)]
|
||||
#[derive(Debug, Clone, Copy)]
|
||||
pub struct Status {
|
||||
status_code: StatusCode,
|
||||
reply_type: ReplyType,
|
||||
|
|
Loading…
Reference in a new issue