Skip to main content

initialize method

void initialize (List<LikedBy> likedBy, String postID)

Implementation

void initialize(List\<LikedBy\> likedBy, String postID) \{
_postID = postID;
_user = _userConfig.currentUser;
_likedBy = likedBy;
notifyListeners();
checkAndSetTheIsLiked();
_updatePostSubscription =
_postService.updatedPostStream.listen((post) =\> updatePost(post));
\}