function user_comment_view

Implements hook_comment_view().

File

modules/user/user.module, line 3578

Code

function user_comment_view($comment) {
    if (variable_get('user_signatures', 0) && !empty($comment->signature)) {
        // @todo This alters and replaces the original object value, so a
        //   hypothetical process of loading, viewing, and saving will hijack the
        //   stored data. Consider renaming to $comment->signature_safe or similar
        //   here and elsewhere in Drupal 8.
        $comment->signature = check_markup($comment->signature, $comment->signature_format, '', TRUE);
    }
    else {
        $comment->signature = '';
    }
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.