Open flosse opened 7 years ago
@flosse I'm not sure that we should expose Iron here because Rustless possibly can work with another backend.
I'm not sure that we should expose Iron here because Rustless possibly can work with another backend.
I see. So accessing iron extensions is generally not possible?
@flosse I'll try to make something with it.
The main problem is that we use backend::Request
as a Trait, but Pluggable
methods are not object-safe.
So we have two ways to fix this:
get_iron_request() -> iron::Request
method.
- Expose Iron request as-is instead of our trait (with "iron" feature).
No, I think that will cause troubles :-\
Expose
get_iron_request() -> iron::Request
method.
That's better, because it's explicit but I'd call it just iron_request()
.
How can I get access to the iron request?
For example with the
persistent
crate, I'd do s.th. like this:but
client.request
is not the irons request object.