updateComment method
Future<void>
updateComment(
{
})
Implementation
Future<void> updateComment({
required final String feedId,
required final String commentId,
required final Map<String, dynamic> data,
final Function(String)? onSuccess,
final Function(dynamic)? onError,
}) async {
try {
final _commentRef =
PeamanReferenceHelper.commentsCol(feedId: feedId).doc(commentId);
await _commentRef.update(data);
print('Success: Updating comment $commentId');
onSuccess?.call(feedId);
} catch (e) {
print(e);
print('Error!!!: Updating comment');
onError?.call(e);
}
}