Commit ed3f6baa authored by 杨培's avatar 杨培

增加论坛用户的关注与取关接口

parent 6e671fd1
......@@ -100,4 +100,33 @@ class User extends Client
return self::call('user.inactive', compact('uIds'));
}
/**
* 关注一个用户
*
* @param int $uid 当前用户UID
* @param int $followUid 要关注的用户UID
* @param bool $silent 是否静默关注,是则不会发送消息提示,默认否
* @return void
* @throws \internalApi\base\ApiException
* @throws \internalApi\base\ClientException
*/
public static function follow($uid, $followUid, $silent=false)
{
return self::call('user.follow', compact('uid', 'followUid'));
}
/**
* 取消关注一个用户
*
* @param int $uid 当前用户UID
* @param int $unfollowUid 要取消关注的用户UID
* @return void
* @throws \internalApi\base\ApiException
* @throws \internalApi\base\ClientException
*/
public static function unfollow($uid, $unfollowUid)
{
return self::call('user.unfollow', compact('uid', 'unfollowUid'));
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment