Browse Source

[PR #1844] Fixed URLConvertible compiler issue in the README example.

zhongwuzw 9 years ago
parent
commit
05c9bcdcf4
1 changed files with 2 additions and 2 deletions
  1. 2 2
      README.md

+ 2 - 2
README.md

@@ -1012,8 +1012,8 @@ Alamofire.request(urlString, method: .post)
 let url = URL(string: urlString)!
 let url = URL(string: urlString)!
 Alamofire.request(url, method: .post)
 Alamofire.request(url, method: .post)
 
 
-let urlComponents = URLComponents(url: url, resolvingAgainstBaseURL: true)
-Alamofire.request(.post, URLComponents)
+let urlComponents = URLComponents(url: url, resolvingAgainstBaseURL: true)!
+Alamofire.request(urlComponents, method: .post)
 ```
 ```
 
 
 Applications interacting with web applications in a significant manner are encouraged to have custom types conform to `URLConvertible` as a convenient way to map domain-specific models to server resources.
 Applications interacting with web applications in a significant manner are encouraged to have custom types conform to `URLConvertible` as a convenient way to map domain-specific models to server resources.