浏览代码

Merge pull request #93 from johngibb/patch-1

JSON parameter encoding no longer has options
Mattt Thompson 11 年之前
父节点
当前提交
f2a8a1c84f
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      README.md

+ 2 - 2
README.md

@@ -128,7 +128,7 @@ Alamofire has built-in support for encoding parameters as URL query / URI form e
 ```swift
 enum ParameterEncoding {
     case URL
-    case JSON(options: NSJSONWritingOptions)
+    case JSON
     case PropertyList(format: NSPropertyListFormat,
                       options: NSPropertyListWriteOptions)
 
@@ -153,7 +153,7 @@ let encoding = Alamofire.ParameterEncoding.URL
 ### POST Request with JSON Response
 
 ```swift
-Alamofire.request(.POST, "http://httpbin.org/post", parameters: parameters, encoding: .JSON(options: nil))
+Alamofire.request(.POST, "http://httpbin.org/post", parameters: parameters, encoding: .JSON)
          .responseJSON {(request, response, JSON, error) in
             println(JSON)
          }