You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, this library can only return Float value when using .progress directive.
However, Alamofire and other network libraries return Progress instance instead of Float.
I think thenPromise should be able to return Progress instance on .progress directive.
For example:
return Promise<URL>{ resolve, reject, progress inAlamofire.download(escapedUrl, to: destination).downloadProgress{ downloadProgress in// downloadProgress is Progress class// let currentProgress = Float(downloadProgress.completedUnitCount) / Float(downloadProgress.totalUnitCount)// progress(currentProgress)progress(downloadProgress)// <- should be able to write like this}.response{ response in...}}
The text was updated successfully, but these errors were encountered:
Currently, this library can only return
Float
value when using.progress
directive.However, Alamofire and other network libraries return
Progress
instance instead ofFloat
.I think thenPromise should be able to return
Progress
instance on.progress
directive.For example:
The text was updated successfully, but these errors were encountered: