Skip to content

Commit

Permalink
feature/openy_repeat_schedule_for_lb|Added a possibility to to add th…
Browse files Browse the repository at this point in the history
…e Repeat Schedules block to LB pages.
  • Loading branch information
oleh-rymar committed Apr 16, 2024
1 parent b19afce commit be375ec
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Plugin/Block/RepeatSchedulesBlock.php
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,9 @@ public function build() {
$block = $this->blockContentStorage->loadByProperties(['revision_id' => $configuration['block_revision_id']]);
if (!empty($block)) {
$block = reset($block);
if ($block instanceof BlockInterface && $block->hasField('field_rs_block') && !$block->get('field_rs_block')->isEmpty()) {
if ($block instanceof BlockInterface &&
$block->hasField('field_rs_block') &&
!$block->get('field_rs_block')->isEmpty()) {
$paragraphs = $block->get('field_rs_block')->referencedEntities();
break 2;
}
Expand Down

0 comments on commit be375ec

Please sign in to comment.