diff options
| author | Owen Jacobson <owen@grimoire.ca> | 2022-06-07 22:03:23 -0400 |
|---|---|---|
| committer | Owen Jacobson <owen@grimoire.ca> | 2022-06-08 00:43:44 -0400 |
| commit | 9fa89e735859d008673663b740c217d0731e71e1 (patch) | |
| tree | b99916754d40c24125b7764eeafaec6851c0face /src/view.rs | |
| parent | 77f19a9f86b1395f0c74e0860c9466b848a3052f (diff) | |
Move back to stable rust.
`maud`, which was the main reason for nightlies, relies on proc macros. Those are stable in the 2021 edition, and maud 0.23+ uses them in a stable-friendly way.
Diffstat (limited to 'src/view.rs')
| -rw-r--r-- | src/view.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/view.rs b/src/view.rs index f6413e8..ad26607 100644 --- a/src/view.rs +++ b/src/view.rs @@ -60,7 +60,7 @@ //! links to existing items are not invalidated or changed - the `item` //! parameter to the `/` endpoint is a literal index into this list. -use actix_web::{error, get, post, web, HttpResponse, Responder}; +use actix_web::{error, get, post, web, HttpRequest, HttpResponse, Responder}; use maud::{html, Markup, PreEscaped, DOCTYPE}; use pulldown_cmark::{html, Options, Parser}; use rand::seq::SliceRandom; @@ -98,7 +98,7 @@ trait Urls { fn index_url(&self, query: ItemQuery) -> Result<url::Url, UrlError>; } -impl Urls for web::HttpRequest { +impl Urls for HttpRequest { fn index_url(&self, query: ItemQuery) -> Result<url::Url, UrlError> { let mut url = self.url_for("index", iter::empty::<&str>())?; @@ -228,7 +228,7 @@ fn index_view(req: impl Urls, idx: &usize, thing: &Thing) -> MarkupResult { #[get("/")] async fn index( - req: web::HttpRequest, + req: HttpRequest, data: web::Data<Things>, query: web::Query<ItemQuery>, ) -> error::Result<impl Responder> { |
