mixpanel/mixpanel-android — Issue #5: Clear super properties should not null the object
Author: yigit
Created: 2012-02-17 02:15:17+00:00
State: open

[MPMetrics#clearSuperProperties] (https://github.com/mixpanel/mixpanel-android/blob/master/src/com/mixpanel/android/mpmetrics/MPMetrics.java#L110) method null's the super parameters object instead of setting it to a fresh JSONObject.
Because track and registerSuperProperties methods does not check if mSuperProperties is null or not, this causes a crash.

Steps to reproduce:
```
MPMetrics mpm = new MPMetrics(context);
mpm.clearSuperProperties();
mpm.registerSuperProperties(newSuperParameters); //crash happens on MPMetrics line 100
```