AnsPress_Notification_Hook::insert_reputation( integer $reputation_id, integer $user_id, string $event, integer $ref_id )
Description #
Notify user on new reputation.
Parameters #
- $reputation_idinteger (Required) Reputation id.
- $user_idinteger (Required) User id.
- $eventstring (Required) Reputation event.
- $ref_idinteger (Required) Reputation reference id.
Source #
File: addons/free/notification.php
public static function insert_reputation( $reputation_id, $user_id, $event, $ref_id ) { ap_insert_notification( array( 'user_id' => $user_id, 'ref_id' => $reputation_id, 'ref_type' => 'reputation', 'verb' => ap_get_reputation_event_points( $event ) > 0 ? 'new_points' : 'lost_points', ) ); }
Expand full source code Collapse full source code View on GitHub: addons/free/notification.php:408
Add your comment