title: UITextField shouldChangeCharactersInRange fires twice?
body: <p>I have a table view. In <code>cellForRowAtIndexPath</code> I have a cell and in that cell there is UITextField. I set textfield's delegate like this: <code>cell.textField.delegate = self;</code>. I need to call my API on third character. So when user types 3 character in textfield, API is called hence <code>shouldChangeCharactersInRange</code>.</p>
  
  <pre><code>- (BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRange)range replacementString:(NSString *)string {
     if (textField.text.length &gt;= 2) {
       NSString *substring = [NSString stringWithString:textField.text];
       substring = [substring
                   stringByReplacingCharactersInRange:range withString:string];
      [API CALLED WITH BLOCK WITH TEXTFIELD TEXT AS PARAMETER:substring];
   }
    return YES;
  }
  </code></pre>
  
  <p>The problem is that when I type for example "abc" <code>shouldChangeCharactersInRange</code> is called first time and parameter is "abc". Second after, <code>shouldChangeCharactersInRange</code> is again called and my textfield has another added character which I did not type and it is always last character that is copied. So in this example, it sends "abcc". Do you know, what is the problem?</p>