Skip to content

Commit

Permalink
fix like bug
Browse files Browse the repository at this point in the history
  • Loading branch information
j03-dev committed Oct 13, 2023
1 parent d6f123d commit 6f52950
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/hooks/messages.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ pub struct Recipient {

#[derive(Debug, Clone, Default, Deserialize)]
pub struct Message {
text: String,
text: Option<String>,
}

impl Message {
pub fn get_text(&self) -> &String {
&self.text
pub fn get_text(&self) -> String {
self.text.unwrap_or("".into())
}
}

Expand Down

0 comments on commit 6f52950

Please sign in to comment.