1. Users can set the API URL now.
2. Added a delegate to the MixpanelAPI Object. Now
users can be notified and block the API from
sending events to the server.
3. Added a flag to automatically send the device
4. Changed the default URL to use https.
1. The expiration handler for beginBackgroundTask was cancelling the connection, but not setting self.connection = nil, which would prevent all future connections from going out.
2. Remove an extraneous attempt to start a NSURLConnection. [NSURLConnection connectionWithRequest:delegate:] creates a connection that is started immediately, and the documentation is unclear as to whether start is an idempotent method.
- It appears that allocating and autoreleasing a CTTelephonyNetworkInfo from a class method causes a dereferencing exception, which causes a crash. This only happens on devices with an active and valid data service (only tested on iPhones but it might also affect iPads with cell data network access) by turning off Airplane mode and turning it back on and switching quickly to the app.
We want to be very deliberate about merging, so we may let individual pull requests live for a while. That doesn't mean we've forgotten them! We just want to carefully consider the changes, and the possible effects on Mixpanel users.