mirror of
https://github.com/actix/actix-website
synced 2024-11-24 00:41:07 +01:00
Fix param name in db example (#191)
This commit is contained in:
parent
e7ca7fddd7
commit
c5e185ae85
@ -46,7 +46,7 @@ async fn main() -> io::Result<()> {
|
||||
// </main>
|
||||
|
||||
// <index>
|
||||
async fn index(req: web::Data<DbPool>, name: web::Path<(String)>) -> impl Responder {
|
||||
async fn index(pool: web::Data<DbPool>, name: web::Path<(String)>) -> impl Responder {
|
||||
let name = name.into_inner();
|
||||
|
||||
let conn = pool.get().expect("couldn't get db connection from pool");
|
||||
|
Loading…
Reference in New Issue
Block a user