I have the following code:
typealias queryCompletionBlock = (_ finished:Bool) -> Void
func queryForParams(@escaping completion:queryCompletionBlock)
But I get an error
Attribute can only be applied to types, not declarations
The problem is the function requires block to be escaping. How do I declare the above function with an escaping block?
func queryForParams(completion: @escaping queryCompletionBlock)
try func queryForParams(completion: @escaping queryCompletionBlock)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With