Zac Zac - 1 year ago 259
Swift Question

dispatch_group_async function in swift 3.0

My question is how to correctly translate this function in Swift 3 because i noticed there is a lot of documentation about

but there isn't anything about

dispatch_group_async(group, dispatch_get_global_queue(QOS_CLASS_USER_INITIATED, 0)) { [unowned self] in

Answer Source

Try this:

let group = DispatchGroup() .userInitiated)
    .async(group:group) { [unowned self] in
        // code