Skip to content
Snippets Groups Projects
Commit 957feb0c authored by Angie Byron's avatar Angie Byron
Browse files

#404116 by neclimdul: Provide default choices on poll translations.

parent 4ffebc57
No related branches found
No related tags found
2 merge requests!7452Issue #1797438. HTML5 validation is preventing form submit and not fully...,!789Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
......@@ -411,6 +411,15 @@ function poll_validate($node, $form) {
}
}
/**
* Implementation of hook_node_prepare_translation().
*/
function poll_node_prepare_translation($node) {
if ($node->type == 'poll') {
$node->choice = $node->translation_source->choice;
}
}
/**
* Implementation of hook_load().
*/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment