ios - Completion handler is not called -


pardon me beginner's question, have function completion handler, it's not called when function complete. tip? thanks

    func updatedailylength(completion: ()-> void ) {           //do here     } 

and in caller:

updatedailylength(completion: { getmonthlydistance() }) 

the function getmonthlydistance() never called.

you need call updatedailylength

func updatedailylength(completion: ()-> void ) {       completion() } 

Comments

Popular posts from this blog

php - How to add and update images or image url in Volusion using Volusion API -

javascript - jQuery UI Splitter/Resizable for unlimited amount of columns -

javascript - IE9 error '$'is not defined -