Spaces:
Running
Running
ddotthomas
commited on
Commit
·
db1115f
1
Parent(s):
4f4cb22
fix: add comma separator and format macro
Browse files
src/server/routes/search.rs
CHANGED
@@ -138,7 +138,7 @@ async fn results(
|
|
138 |
|
139 |
// We sort the list of engine so the cache keys will match between users. The cookie's list of engines is unordered.
|
140 |
engines.sort();
|
141 |
-
cache_key = cache_key
|
142 |
} else {
|
143 |
let mut engines: Vec<String> = config
|
144 |
.upstream_search_engines
|
@@ -148,7 +148,7 @@ async fn results(
|
|
148 |
.collect();
|
149 |
|
150 |
engines.sort();
|
151 |
-
cache_key = cache_key
|
152 |
}
|
153 |
|
154 |
// fetch the cached results json.
|
|
|
138 |
|
139 |
// We sort the list of engine so the cache keys will match between users. The cookie's list of engines is unordered.
|
140 |
engines.sort();
|
141 |
+
cache_key = format!("{}{}", cache_key, engines.join(","));
|
142 |
} else {
|
143 |
let mut engines: Vec<String> = config
|
144 |
.upstream_search_engines
|
|
|
148 |
.collect();
|
149 |
|
150 |
engines.sort();
|
151 |
+
cache_key = format!("{}{}", cache_key, engines.join(","));
|
152 |
}
|
153 |
|
154 |
// fetch the cached results json.
|