Skip to main content

Filter: gk/gravityboard/voting/can-spend-vote

Filters whether a user can spend a vote.

Return true to allow or a WP_Error to deny with a message.

Parameters​

NameTypeDescription
$allowedtrueWhether the vote is allowed.
$feed_idintThe feed ID.
$user_idintThe user ID.
$entry_idintThe entry (card) ID.
$budgetarray\{total: int, used: int, remaining: int, is_unlimited: bool, period: string, resets_at: string|null\}Budget info from get_budget().

Since​

  • 1.4.0

Source​

Defined in src/Voting/VoteBudget.php at line 142