update method
void
update({
- required UCommentUpdateParams p,
- required dynamic onOk(),
- required dynamic onError(),
- dynamic onException()?,
Implementation
void update({
required final UCommentUpdateParams p,
required final Function(UResponse<UCommentResponse> r) onOk,
required final Function(UResponse<dynamic> e) onError,
final Function(Exception)? onException,
}) =>
httpClient.post(
"/comment/Update",
body: p.toMap().add("apiKey", apiKey).add("token", token),
onSuccess: (final String r) => onOk(UResponse<UCommentResponse>.fromJson(r, (final dynamic i) => UCommentResponse.fromMap(i))),
onError: (final String r) => onError(UResponse<dynamic>.fromJson(r, (final dynamic i) => i)),
onException: (final dynamic e) {
if (onException != null) onException(e);
},
);