summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSam Tay <sam.chong.tay@gmail.com>2020-06-24 16:48:36 -0700
committerSam Tay <sam.chong.tay@gmail.com>2020-06-25 02:10:33 -0700
commit3216d47824f3f15e11a60132b2c559fc4796d59c (patch)
treee237db0c84b27d6ba94769ff6e00a412c9d28118 /src
parent1a18145d77b1605dab2d1b1cd18a8cf940ea489c (diff)
Update docs
Diffstat (limited to 'src')
-rw-r--r--src/config.rs2
-rw-r--r--src/stackexchange/scraper.rs2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/config.rs b/src/config.rs
index 0154cda..987a887 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -47,7 +47,7 @@ impl Default for SearchEngine {
impl Default for Config {
fn default() -> Self {
Config {
- api_key: None,
+ api_key: Some(String::from("8o9g7WcfwnwbB*Qp4VsGsw((")),
limit: 20,
lucky: true,
sites: vec![String::from("stackoverflow")],
diff --git a/src/stackexchange/scraper.rs b/src/stackexchange/scraper.rs
index 2f62eb6..b03c577 100644
--- a/src/stackexchange/scraper.rs
+++ b/src/stackexchange/scraper.rs
@@ -176,6 +176,7 @@ fn parse_with_selector(
})
}
+// TODO also allow /q/
/// For example
/// ```
/// let id = "stackoverflow.com";
@@ -191,6 +192,7 @@ fn question_url_to_id(site_url: &str, input: &str) -> Option<String> {
Some(input[0..end].to_string())
}
+// TODO test with google/parsing-q.html
#[cfg(test)]
mod tests {
use super::*;