You are here

function heartbeat_comments_get_count_label in Heartbeat 7

Helper function to fetch the button to comment.

2 calls to heartbeat_comments_get_count_label()
HeartbeatActivityCommentsPlugin::renderButtons in modules/heartbeat_comments/plugins/activitycomments.inc
renderButtons().
heartbeat_comments_form_submit in modules/heartbeat_comments/heartbeat_comments.module
User submitted a heartbeat comment.

File

modules/heartbeat_comments/heartbeat_comments.module, line 877
Heartbeat comments for activity.

Code

function heartbeat_comments_get_count_label($count) {
  if ($count > 1) {
    $label = t('@count comments', array(
      '@count' => $count,
    ));
  }
  elseif ($count == 1) {
    $label = t('1 comment');
  }
  else {
    $label = t('Comment');
  }
  return $label;
}