Skip to content

Commit

Permalink
Fixed an error
Browse files Browse the repository at this point in the history
  • Loading branch information
Pavlo Dumyak committed Nov 21, 2020
1 parent c9acb44 commit 113a8a8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Requesto.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |spec|
spec.name = 'Requesto'
spec.version = '0.0.3'
spec.version = '0.0.4'
spec.authors = {
'Pavlo Dumiak' => '[email protected]'
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,11 @@
<key>orderHint</key>
<integer>0</integer>
</dict>
<key>Requesto.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
</dict>
</plist>
7 changes: 0 additions & 7 deletions Requesto/Core/ExecutiveRequestHandler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,9 @@ open class ExecutiveRequestHandler: RequestHandler {
}

func processRequest<T>(request: Request, error: Error?, type: T.Type) where T : Decodable {
var error = error
let serviceRequest = request.buildURLRequest()
let semaphore = DispatchSemaphore.init(value: 0)
let task = URLSession.shared.dataTask(with: serviceRequest) { data, response, networkError in
if request.canceled {
print("request cancelled: \(request)")
} else if let networkError = networkError {
error = networkError
}

let result = RequestParser().parse(object: data, objectType: type, response: response)
switch result {
case .success:
Expand Down

0 comments on commit 113a8a8

Please sign in to comment.