We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3079eb3 commit a0747e9Copy full SHA for a0747e9
1 file changed
crates/bin/docs_rs_web/src/handlers/sitemap.rs
@@ -38,13 +38,7 @@ pub(crate) async fn sitemapindex_handler() -> impl IntoResponse {
38
let sitemaps: Vec<char> = ('a'..='z').collect();
39
let today = Utc::now().date_naive();
40
let recent_sitemaps = (0..RECENT_SITEMAP_DAYS)
41
- .map(|days| {
42
- today
43
- .checked_sub_days(Days::new(days))
44
- .expect("underflow when building recent sitemap dates")
45
- .format("%F")
46
- .to_string()
47
- })
+ .map(|days| (today + Days::new(days)).format("%F").to_string())
48
.collect();
49
50
SitemapIndex {
0 commit comments