Hi again,
would it be possible to have votingapi_get_user_votes() return the votes for the current user by default, when NULL is passed as uid ?
This would be the patch:
Change
function votingapi_get_user_votes($content_type, $content_id, $uid) {
return _votingapi_get_raw_votes($content_type, $content_id, NULL, NULL, $uid);
}
To:
function votingapi_get_user_votes($content_type, $content_id, $uid = NULL) {
global $user;
if($uid == NULL) { $uid = $user->uid; }
return _votingapi_get_raw_votes($content_type, $content_id, NULL, NULL, $uid);
}
Comments
Comment #1
eaton commentedChecked in. Thanks!
Comment #2
(not verified) commented