This commit is contained in:
spikecodes 2021-01-12 19:52:02 -08:00
parent 89fa0d5489
commit eb9a0dcb4a
5 changed files with 25 additions and 20 deletions

View file

@ -117,7 +117,7 @@ async fn parse_comments(json: &serde_json::Value) -> Vec<Comment> {
// Separate the comment JSON into a Vector of comments
let comment_data = match json["data"]["children"].as_array() {
Some(f) => f.to_owned(),
None => { let v = Vec::new(); v }
None => Vec::new(),
};
let mut comments: Vec<Comment> = Vec::new();