example FromRequest process for User Authentication. querying database each process #1764
Unanswered
eisenhaus335
asked this question in
Questions
Replies: 1 comment
-
The page you linked to does access the database inside of let db = try_outcome!(request.guard::<Database>().await); The Can you be more specific about which line(s) of code you are having trouble with? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I trying to figure out on how to make FromRequest guard while also using database service. I use some idea where https://api.rocket.rs/v0.5-rc/rocket/request/trait.FromRequest.html are explained here on how to handle user guard. I cant figure out how to make this making 'guard' from the examples/database, there are no example on processing database inside FromRequest . rust-analyzer also not showing good information due macro is complex there, or perhaps is just me that doesn't understand it
Here is the link for my recent work https://github.com/eisenhaus335/rockety_backend
Beta Was this translation helpful? Give feedback.
All reactions