EntityService.Like Method

Namespace:
Weavy.Core.Services
Assembly:
Weavy.Core.dll

Like(TLikeable, int?, bool)

Like the specified entity.

public static TLikeable Like<TLikeable>(TLikeable likeable, int? userId = default(int? ), bool sudo = false)
    where TLikeable : class, ILikeable

Parameters

likeable

The entity to like.

userId
int?

Id of the User that likes, default is null which indicates the current user.

sudo
bool

true to perform action as super user, otherwise false.

Returns

The liked entity.