Handle about pages

This commit is contained in:
spikecodes 2021-02-21 10:13:20 -08:00
parent de38f7ef18
commit 518d5753a7
No known key found for this signature in database
GPG Key ID: 004CECFF9B463BCB
1 changed files with 3 additions and 0 deletions

View File

@ -240,6 +240,9 @@ async fn main() -> tide::Result<()> {
// Search all of Reddit
app.at("/search/").get(search::find);
// Handle about pages
app.at("/about/").get(|req| error(req, "About pages aren't here yet".to_string()));
app.at("/:id/").get(|req: Request<()>| async {
match req.param("id") {
// Sort front page