Spaces:
Runtime error
Runtime error
neon_arch
commited on
Commit
β’
72da323
1
Parent(s):
2bdddaf
ποΈ fix(engine): fix the pagination code for `searx` engine (#468)
Browse files- src/engines/searx.rs +4 -8
src/engines/searx.rs
CHANGED
@@ -50,14 +50,10 @@ impl SearchEngine for Searx {
|
|
50 |
safe_search = 2;
|
51 |
};
|
52 |
|
53 |
-
let url: String =
|
54 |
-
|
55 |
-
|
56 |
-
|
57 |
-
_ => {
|
58 |
-
format!("https://searx.be/search?q={query}&pageno={page}&safesearch={safe_search}")
|
59 |
-
}
|
60 |
-
};
|
61 |
|
62 |
// initializing headers and adding appropriate headers.
|
63 |
let header_map = HeaderMap::try_from(&HashMap::from([
|
|
|
50 |
safe_search = 2;
|
51 |
};
|
52 |
|
53 |
+
let url: String = format!(
|
54 |
+
"https://searx.be/search?q={query}&pageno={}&safesearch={safe_search}",
|
55 |
+
page + 1
|
56 |
+
);
|
|
|
|
|
|
|
|
|
57 |
|
58 |
// initializing headers and adding appropriate headers.
|
59 |
let header_map = HeaderMap::try_from(&HashMap::from([
|