1
0
mirror of https://github.com/actix/actix-extras.git synced 2024-11-28 01:32:57 +01:00

fix layout

This commit is contained in:
Nikolay Kim 2018-06-02 09:25:11 -07:00
parent 0457fe4d61
commit 33326ea41b

View File

@ -4,18 +4,19 @@
Instead of Instead of
```run ```rust
fn main() { fn main() {
let sys = actix::System::new(..); let sys = actix::System::new(..);
HttpServer::new(|| ...).start() HttpServer::new(|| ...).start()
sys.run(); sys.run();
} }
``` ```
Server must be initialized within system run closure: Server must be initialized within system run closure:
```run ```rust
fn main() { fn main() {
actix::System::run(|| { actix::System::run(|| {
HttpServer::new(|| ...).start() HttpServer::new(|| ...).start()
@ -32,7 +33,7 @@
* Removed deprecated `HttpServer::threads()`, use `HttpServer::workers()` instead. * Removed deprecated `HttpServer::threads()`, use `HttpServer::workers()` instead.
## Migration from 0.5 to 0.6 ## 0.6
* `Path<T>` extractor return `ErrorNotFound` on failure instead of `ErrorBadRequest` * `Path<T>` extractor return `ErrorNotFound` on failure instead of `ErrorBadRequest`
@ -84,7 +85,7 @@
you need to use `use actix_web::ws::WsWriter` you need to use `use actix_web::ws::WsWriter`
## Migration from 0.4 to 0.5 ## 0.5
* `HttpResponseBuilder::body()`, `.finish()`, `.json()` * `HttpResponseBuilder::body()`, `.finish()`, `.json()`
methods return `HttpResponse` instead of `Result<HttpResponse>` methods return `HttpResponse` instead of `Result<HttpResponse>`