Issue #3276615 by catch, mherchel: Remove olivero_form_comment_form_alter() comment button label override
parent
f8c91fdd71
commit
0f903ca30c
|
@ -494,21 +494,6 @@ function olivero_preprocess_filter_caption(&$variables) {
|
|||
$variables['classes'] = isset($variables['classes']) && !empty($variables['classes']) ? $variables['classes'] . ' caption' : 'caption';
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements hook_form_FORM_ID_alter().
|
||||
*/
|
||||
function olivero_form_comment_form_alter(&$form, FormStateInterface $form_state, $form_id) {
|
||||
$comment = $form_state->getFormObject()
|
||||
->getEntity();
|
||||
/** @var \Drupal\comment\Entity\Comment $comment */
|
||||
if ($comment->hasParentComment()) {
|
||||
$form['actions']['submit']['#value'] = t('Reply to comment');
|
||||
}
|
||||
else {
|
||||
$form['actions']['submit']['#value'] = t('Post comment');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Implements hook_form_FORM_ID_alter().
|
||||
*/
|
||||
|
|
Loading…
Reference in New Issue