Skip to content

web search done right

Hours are rounded, not stripped

Mikkel Denkera8dfdf5df8cc
diff --git a/core/src/query_store.rs b/core/src/query_store.rs
index 2448d1b8..67446347 100644
--- a/core/src/query_store.rs
+++ b/core/src/query_store.rs
@@ -40,14 +40,13 @@ pub struct StoredQuery {
qid: Uuid,
query: String,
result_urls: Vec<Url>,
- timestamp: Option<DateTime<Utc>>, // it is extremely important that we strip hours, minutes, seconds and nanoseconds here for privacy
+ timestamp: Option<DateTime<Utc>>, // it is extremely important that we strip minutes, seconds and nanoseconds here for privacy
}
impl StoredQuery {
pub fn new(query: String, urls: Vec<Url>) -> Self {
let timestamp = Utc::now()
.with_minute(0)
- .and_then(|t| t.with_minute(0))
.and_then(|t| t.with_second(0))
.and_then(|t| t.with_nanosecond(0));