diff options
author | cel 🌸 <cel@blos.sm> | 2024-01-31 18:55:36 +0000 |
---|---|---|
committer | cel 🌸 <cel@blos.sm> | 2024-01-31 18:55:36 +0000 |
commit | d1bfe2eb0ba8836d4eef4ca5dd6e20611dc3a8c0 (patch) | |
tree | c54999785bf7ae865ca571a475da222e9e376873 /src/blog.rs | |
parent | b78d026c242e8d95e611e050afd5b72eb562d56d (diff) | |
download | blossom-d1bfe2eb0ba8836d4eef4ca5dd6e20611dc3a8c0.tar.gz blossom-d1bfe2eb0ba8836d4eef4ca5dd6e20611dc3a8c0.tar.bz2 blossom-d1bfe2eb0ba8836d4eef4ca5dd6e20611dc3a8c0.zip |
changed Post tags() to return a Vec<&str>
Diffstat (limited to 'src/blog.rs')
-rw-r--r-- | src/blog.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/blog.rs b/src/blog.rs index 0e757d5..b6ca75c 100644 --- a/src/blog.rs +++ b/src/blog.rs @@ -76,8 +76,8 @@ impl Post for Blogpost { self.updated_at.as_ref() } - fn tags(&self) -> &Vec<String> { - &self.tags + fn tags(&self) -> Vec<&str> { + self.tags.iter().map(|s| &**s).collect() } fn lang(&self) -> &str { |