{"action":"created","comment":{"url":"https://api.github.com/repos/Moya/Moya/pulls/comments/45940595","id":45940595,"diff_hunk":"@@ -5,30 +5,10 @@ import Alamofire\n public typealias Completion = (data: NSData?, statusCode: Int?, response: NSURLResponse?, error: ErrorType?) -> ()\n \n /// Represents an HTTP method.\n-public enum Method {\n-    case GET, POST, PUT, DELETE, OPTIONS, HEAD, PATCH, TRACE, CONNECT\n-\n-    func method() -> Alamofire.Method {\n-        switch self {\n-        case .GET:\n-            return .GET\n-        case .POST:\n-            return .POST\n-        case .PUT:\n-            return .PUT\n-        case .DELETE:\n-            return .DELETE\n-        case .HEAD:\n-            return .HEAD\n-        case .OPTIONS:\n-            return .OPTIONS\n-        case PATCH:\n-            return .PATCH\n-        case TRACE:\n-            return .TRACE\n-        case .CONNECT:\n-            return .CONNECT\n-        }\n+public enum Method: String {\n+    case GET = \"GET\", POST = \"POST\", PUT = \"PUT\", DELETE = \"DELETE\", OPTIONS = \"OPTIONS\", HEAD = \"HEAD\", PATCH = \"PATCH\", TRACE = \"TRACE\", CONNECT = \"CONNECT\"\n+    public var method: Alamofire.Method {\n+        return Alamofire.Method(rawValue: rawValue)!","path":"Source/Moya.swift","position":31,"original_position":31,"commit_id":"9db4c50791bf016f40475f5b4cb0c8f9d8f41ea2","original_commit_id":"9db4c50791bf016f40475f5b4cb0c8f9d8f41ea2","user":{"login":"petester42","id":296718,"avatar_url":"https://avatars.githubusercontent.com/u/296718?v=3","gravatar_id":"","url":"https://api.github.com/users/petester42","html_url":"https://github.com/petester42","followers_url":"https://api.github.com/users/petester42/followers","following_url":"https://api.github.com/users/petester42/following{/other_user}","gists_url":"https://api.github.com/users/petester42/gists{/gist_id}","starred_url":"https://api.github.com/users/petester42/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petester42/subscriptions","organizations_url":"https://api.github.com/users/petester42/orgs","repos_url":"https://api.github.com/users/petester42/repos","events_url":"https://api.github.com/users/petester42/events{/privacy}","received_events_url":"https://api.github.com/users/petester42/received_events","type":"User","site_admin":false},"body":"is there any plans to use this mapping function? Because I just noticed it is never used. We could just remove it :stuck_out_tongue: ","created_at":"2015-11-26T03:01:59Z","updated_at":"2015-11-26T03:01:59Z","html_url":"https://github.com/Moya/Moya/pull/307#discussion_r45940595","pull_request_url":"https://api.github.com/repos/Moya/Moya/pulls/307","_links":{"self":{"href":"https://api.github.com/repos/Moya/Moya/pulls/comments/45940595"},"html":{"href":"https://github.com/Moya/Moya/pull/307#discussion_r45940595"},"pull_request":{"href":"https://api.github.com/repos/Moya/Moya/pulls/307"}}},"pull_request":{"url":"https://api.github.com/repos/Moya/Moya/pulls/307","id":50835836,"html_url":"https://github.com/Moya/Moya/pull/307","diff_url":"https://github.com/Moya/Moya/pull/307.diff","patch_url":"https://github.com/Moya/Moya/pull/307.patch","issue_url":"https://api.github.com/repos/Moya/Moya/issues/307","number":307,"state":"open","locked":false,"title":"Plugins are now a protocol.","user":{"login":"swizzlr","id":1848665,"avatar_url":"https://avatars.githubusercontent.com/u/1848665?v=3","gravatar_id":"","url":"https://api.github.com/users/swizzlr","html_url":"https://github.com/swizzlr","followers_url":"https://api.github.com/users/swizzlr/followers","following_url":"https://api.github.com/users/swizzlr/following{/other_user}","gists_url":"https://api.github.com/users/swizzlr/gists{/gist_id}","starred_url":"https://api.github.com/users/swizzlr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/swizzlr/subscriptions","organizations_url":"https://api.github.com/users/swizzlr/orgs","repos_url":"https://api.github.com/users/swizzlr/repos","events_url":"https://api.github.com/users/swizzlr/events{/privacy}","received_events_url":"https://api.github.com/users/swizzlr/received_events","type":"User","site_admin":false},"body":"Dependes on #305","created_at":"2015-11-16T16:55:31Z","updated_at":"2015-11-26T03:01:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"fe2dd335610d8fdbc96371f81ba04510912737a0","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Moya/Moya/pulls/307/commits","review_comments_url":"https://api.github.com/repos/Moya/Moya/pulls/307/comments","review_comment_url":"https://api.github.com/repos/Moya/Moya/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Moya/Moya/issues/307/comments","statuses_url":"https://api.github.com/repos/Moya/Moya/statuses/9db4c50791bf016f40475f5b4cb0c8f9d8f41ea2","head":{"label":"Moya:swizzlr/protocol-plugins","ref":"swizzlr/protocol-plugins","sha":"9db4c50791bf016f40475f5b4cb0c8f9d8f41ea2","user":{"login":"Moya","id":13662162,"avatar_url":"https://avatars.githubusercontent.com/u/13662162?v=3","gravatar_id":"","url":"https://api.github.com/users/Moya","html_url":"https://github.com/Moya","followers_url":"https://api.github.com/users/Moya/followers","following_url":"https://api.github.com/users/Moya/following{/other_user}","gists_url":"https://api.github.com/users/Moya/gists{/gist_id}","starred_url":"https://api.github.com/users/Moya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Moya/subscriptions","organizations_url":"https://api.github.com/users/Moya/orgs","repos_url":"https://api.github.com/users/Moya/repos","events_url":"https://api.github.com/users/Moya/events{/privacy}","received_events_url":"https://api.github.com/users/Moya/received_events","type":"Organization","site_admin":false},"repo":{"id":23013268,"name":"Moya","full_name":"Moya/Moya","owner":{"login":"Moya","id":13662162,"avatar_url":"https://avatars.githubusercontent.com/u/13662162?v=3","gravatar_id":"","url":"https://api.github.com/users/Moya","html_url":"https://github.com/Moya","followers_url":"https://api.github.com/users/Moya/followers","following_url":"https://api.github.com/users/Moya/following{/other_user}","gists_url":"https://api.github.com/users/Moya/gists{/gist_id}","starred_url":"https://api.github.com/users/Moya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Moya/subscriptions","organizations_url":"https://api.github.com/users/Moya/orgs","repos_url":"https://api.github.com/users/Moya/repos","events_url":"https://api.github.com/users/Moya/events{/privacy}","received_events_url":"https://api.github.com/users/Moya/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Moya/Moya","description":"Network abstraction layer written in Swift.","fork":false,"url":"https://api.github.com/repos/Moya/Moya","forks_url":"https://api.github.com/repos/Moya/Moya/forks","keys_url":"https://api.github.com/repos/Moya/Moya/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Moya/Moya/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Moya/Moya/teams","hooks_url":"https://api.github.com/repos/Moya/Moya/hooks","issue_events_url":"https://api.github.com/repos/Moya/Moya/issues/events{/number}","events_url":"https://api.github.com/repos/Moya/Moya/events","assignees_url":"https://api.github.com/repos/Moya/Moya/assignees{/user}","branches_url":"https://api.github.com/repos/Moya/Moya/branches{/branch}","tags_url":"https://api.github.com/repos/Moya/Moya/tags","blobs_url":"https://api.github.com/repos/Moya/Moya/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Moya/Moya/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Moya/Moya/git/refs{/sha}","trees_url":"https://api.github.com/repos/Moya/Moya/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Moya/Moya/statuses/{sha}","languages_url":"https://api.github.com/repos/Moya/Moya/languages","stargazers_url":"https://api.github.com/repos/Moya/Moya/stargazers","contributors_url":"https://api.github.com/repos/Moya/Moya/contributors","subscribers_url":"https://api.github.com/repos/Moya/Moya/subscribers","subscription_url":"https://api.github.com/repos/Moya/Moya/subscription","commits_url":"https://api.github.com/repos/Moya/Moya/commits{/sha}","git_commits_url":"https://api.github.com/repos/Moya/Moya/git/commits{/sha}","comments_url":"https://api.github.com/repos/Moya/Moya/comments{/number}","issue_comment_url":"https://api.github.com/repos/Moya/Moya/issues/comments{/number}","contents_url":"https://api.github.com/repos/Moya/Moya/contents/{+path}","compare_url":"https://api.github.com/repos/Moya/Moya/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Moya/Moya/merges","archive_url":"https://api.github.com/repos/Moya/Moya/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Moya/Moya/downloads","issues_url":"https://api.github.com/repos/Moya/Moya/issues{/number}","pulls_url":"https://api.github.com/repos/Moya/Moya/pulls{/number}","milestones_url":"https://api.github.com/repos/Moya/Moya/milestones{/number}","notifications_url":"https://api.github.com/repos/Moya/Moya/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Moya/Moya/labels{/name}","releases_url":"https://api.github.com/repos/Moya/Moya/releases{/id}","created_at":"2014-08-16T07:41:21Z","updated_at":"2015-11-25T17:19:18Z","pushed_at":"2015-11-25T17:20:14Z","git_url":"git://github.com/Moya/Moya.git","ssh_url":"git@github.com:Moya/Moya.git","clone_url":"https://github.com/Moya/Moya.git","svn_url":"https://github.com/Moya/Moya","homepage":"","size":16088,"stargazers_count":1580,"watchers_count":1580,"language":"Swift","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":137,"mirror_url":null,"open_issues_count":17,"forks":137,"open_issues":17,"watchers":1580,"default_branch":"master"}},"base":{"label":"Moya:master","ref":"master","sha":"a7aed0c44941ac9eb8ddc095a710d8b3b3c1bff6","user":{"login":"Moya","id":13662162,"avatar_url":"https://avatars.githubusercontent.com/u/13662162?v=3","gravatar_id":"","url":"https://api.github.com/users/Moya","html_url":"https://github.com/Moya","followers_url":"https://api.github.com/users/Moya/followers","following_url":"https://api.github.com/users/Moya/following{/other_user}","gists_url":"https://api.github.com/users/Moya/gists{/gist_id}","starred_url":"https://api.github.com/users/Moya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Moya/subscriptions","organizations_url":"https://api.github.com/users/Moya/orgs","repos_url":"https://api.github.com/users/Moya/repos","events_url":"https://api.github.com/users/Moya/events{/privacy}","received_events_url":"https://api.github.com/users/Moya/received_events","type":"Organization","site_admin":false},"repo":{"id":23013268,"name":"Moya","full_name":"Moya/Moya","owner":{"login":"Moya","id":13662162,"avatar_url":"https://avatars.githubusercontent.com/u/13662162?v=3","gravatar_id":"","url":"https://api.github.com/users/Moya","html_url":"https://github.com/Moya","followers_url":"https://api.github.com/users/Moya/followers","following_url":"https://api.github.com/users/Moya/following{/other_user}","gists_url":"https://api.github.com/users/Moya/gists{/gist_id}","starred_url":"https://api.github.com/users/Moya/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Moya/subscriptions","organizations_url":"https://api.github.com/users/Moya/orgs","repos_url":"https://api.github.com/users/Moya/repos","events_url":"https://api.github.com/users/Moya/events{/privacy}","received_events_url":"https://api.github.com/users/Moya/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Moya/Moya","description":"Network abstraction layer written in Swift.","fork":false,"url":"https://api.github.com/repos/Moya/Moya","forks_url":"https://api.github.com/repos/Moya/Moya/forks","keys_url":"https://api.github.com/repos/Moya/Moya/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Moya/Moya/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Moya/Moya/teams","hooks_url":"https://api.github.com/repos/Moya/Moya/hooks","issue_events_url":"https://api.github.com/repos/Moya/Moya/issues/events{/number}","events_url":"https://api.github.com/repos/Moya/Moya/events","assignees_url":"https://api.github.com/repos/Moya/Moya/assignees{/user}","branches_url":"https://api.github.com/repos/Moya/Moya/branches{/branch}","tags_url":"https://api.github.com/repos/Moya/Moya/tags","blobs_url":"https://api.github.com/repos/Moya/Moya/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Moya/Moya/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Moya/Moya/git/refs{/sha}","trees_url":"https://api.github.com/repos/Moya/Moya/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Moya/Moya/statuses/{sha}","languages_url":"https://api.github.com/repos/Moya/Moya/languages","stargazers_url":"https://api.github.com/repos/Moya/Moya/stargazers","contributors_url":"https://api.github.com/repos/Moya/Moya/contributors","subscribers_url":"https://api.github.com/repos/Moya/Moya/subscribers","subscription_url":"https://api.github.com/repos/Moya/Moya/subscription","commits_url":"https://api.github.com/repos/Moya/Moya/commits{/sha}","git_commits_url":"https://api.github.com/repos/Moya/Moya/git/commits{/sha}","comments_url":"https://api.github.com/repos/Moya/Moya/comments{/number}","issue_comment_url":"https://api.github.com/repos/Moya/Moya/issues/comments{/number}","contents_url":"https://api.github.com/repos/Moya/Moya/contents/{+path}","compare_url":"https://api.github.com/repos/Moya/Moya/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Moya/Moya/merges","archive_url":"https://api.github.com/repos/Moya/Moya/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Moya/Moya/downloads","issues_url":"https://api.github.com/repos/Moya/Moya/issues{/number}","pulls_url":"https://api.github.com/repos/Moya/Moya/pulls{/number}","milestones_url":"https://api.github.com/repos/Moya/Moya/milestones{/number}","notifications_url":"https://api.github.com/repos/Moya/Moya/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Moya/Moya/labels{/name}","releases_url":"https://api.github.com/repos/Moya/Moya/releases{/id}","created_at":"2014-08-16T07:41:21Z","updated_at":"2015-11-25T17:19:18Z","pushed_at":"2015-11-25T17:20:14Z","git_url":"git://github.com/Moya/Moya.git","ssh_url":"git@github.com:Moya/Moya.git","clone_url":"https://github.com/Moya/Moya.git","svn_url":"https://github.com/Moya/Moya","homepage":"","size":16088,"stargazers_count":1580,"watchers_count":1580,"language":"Swift","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":137,"mirror_url":null,"open_issues_count":17,"forks":137,"open_issues":17,"watchers":1580,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Moya/Moya/pulls/307"},"html":{"href":"https://github.com/Moya/Moya/pull/307"},"issue":{"href":"https://api.github.com/repos/Moya/Moya/issues/307"},"comments":{"href":"https://api.github.com/repos/Moya/Moya/issues/307/comments"},"review_comments":{"href":"https://api.github.com/repos/Moya/Moya/pulls/307/comments"},"review_comment":{"href":"https://api.github.com/repos/Moya/Moya/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Moya/Moya/pulls/307/commits"},"statuses":{"href":"https://api.github.com/repos/Moya/Moya/statuses/9db4c50791bf016f40475f5b4cb0c8f9d8f41ea2"}}}}