trigger-corp/trigger.io-contact — pull request #1 by kflynn (2014-10-14 15:54:56+00:00)
Title: Support forge.contact.insert() to insert contacts without user interaction

While insert() isn't terribly relevant on Android (so far?), it's pretty critical on iOS for Prompt.ly: you need to be able to add a contact, but we need it to behave pretty much the same on both platforms. Thus the insert() method.

One would expect this to be a very simple diff, but, sadly, such was not to be. Here's the problem: on iOS, you were basically not doing any error checking. Even your add() method would fail if you didn't supply every field that it was expecting.

Rather than fix all the instances in your code where this would be a problem, I ripped it all out and switched to known-good code I did a year ago, then updated the tests to cover it as well.

(What's that, you say? A year ago? Yeah. Prompt.ly needed insert() from the beginning, but it seems that I never got you a pull request back then. Mea culpa. Come iOS 8, porting insert() in suddenly became an urgent task, so I want to make sure we don't need to do that again. [ :) ])

I had Android code as well, but as far as I can tell your Android code was running fine, so there seems to be no reason to switch to mine there.

Thanks! and my apologies for misspelling "committed" in 842ecee. [ :) ]