Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to CKEditor 5 #84

Merged
merged 13 commits into from
Dec 22, 2023
Merged

Update to CKEditor 5 #84

merged 13 commits into from
Dec 22, 2023

Conversation

aheaphy
Copy link
Contributor

@aheaphy aheaphy commented Dec 19, 2023

No description provided.

$entity_manager = \Drupal::entityTypeManager();
$mid = $senator->field_member_headshot->target_id;
$media_image = $entity_manager->getStorage('media')->load($mid);
$variables['senator_image'] = !empty($media_image) ? $entity_manager->getViewBuilder('media')->view($media_image, '160x160') : NULL;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to handle potential exceptions, and provide sane default for $variables['senator_image']

@fksaintil fksaintil added the ready Tested and ready for deployment (unless on-hold) label Dec 22, 2023
@kzalewski kzalewski merged commit dbffb10 into main Dec 22, 2023
2 checks passed
@kzalewski kzalewski deleted the feature/nys-19-33--ckeditor branch December 22, 2023 23:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready Tested and ready for deployment (unless on-hold)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants