aboutsummaryrefslogtreecommitdiffstats
path: root/src/request.rs
AgeCommit message (Collapse)Author
2020-07-18FastCgiRequest::path: Get path from `REQUEST_URI`Teddy Wing
Use the `REQUEST_URI` param instead of `SCRIPT_NAME` to get the request path. Using `SCRIPT_NAME` caused issues with redirects. If my FastCGI program has the file name `script.fcgi`, and I set up a redirect from `/script` to `/script.fcgi`, then `path()` should return `/script` when using that path. In the above case, because we were using the `SCRIPT_NAME` param, `path()` would return `/script.fcgi` instead. This caused routes defined with a `RouteBuilder` to not match correctly. Now that we're using `REQUEST_URI`, we need to trim the query string and hash, which are included in the param value, since we only want the URI path.
2020-07-17FastCgiRequest: Implement `conduit::RequestExt::path_mut`Teddy Wing
The latest version of Conduit, 0.9.0-alpha.3, adds a new `path_mut` method.
2020-07-04Add license (GNU GPLv3+)Teddy Wing
2020-07-04request::Error: Remove context from error variantsTeddy Wing
Since we don't need to add any additional context or messages here, we can turn off error context for these variants and shorten error propagation.
2020-07-04Add documentationTeddy Wing
Write doc comments for functions and types, and include a short example.
2020-06-29Rename `request::RequestError` to `request::Error`Teddy Wing
Now that we have a `request` module, the "Request" part of the name is redundant.
2020-06-29FastCgiRequest: Make `scheme()` method privateTeddy Wing
Turns out I didn't need to make it public as we only need to use it within the module.
2020-06-29Move request code to `request.rs`Teddy Wing
Want to separate request and server code.