Currently, I am making an NSURLConnection
whenever mySearchBar.text
did change. I am experiencing an issue whereby if the user enters text too quickly, The respondData
gets corrupted.
So, I was wondering is there a way to check whether the same NSURLConnection
is still loading? If yes, How do I drop the current connection and start a new one?
Add a property for that NSURLConnection and before starting new connection, do:
[self.conn cancel];
self.conn = nil;