Fix onError, onSuccess, adding class optional, mobile support