Skip to content

Commit

Permalink
Better logging on server
Browse files Browse the repository at this point in the history
  • Loading branch information
sergi0g committed Sep 16, 2024
1 parent 0136850 commit 5bf7269
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,13 @@ impl ServerData {
s
}
async fn refresh(&mut self) {
info!("Refreshing data");
let start = Local::now().timestamp_millis();
if !self.raw_updates.is_empty() {
info!("Refreshing data");
}
let updates = sort_update_vec(&get_all_updates(&self.options).await);
let end = Local::now().timestamp_millis();
info!("✨ Checked {} images in {}ms", updates.len(), end - start);
self.raw_updates = updates;
let template = liquid::ParserBuilder::with_stdlib()
.build()
Expand Down

0 comments on commit 5bf7269

Please sign in to comment.