fix optional parameters and callbacks

the problem ocurred when is not pass de parameter "label" or "value" to the function trackEvent returned "JSON error" but is not visible that callback is not implement.