Last active
November 8, 2021 16:03
-
-
Save imcbride/42f4163a5e34733b98c0e2510b052dce to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/Element/LayoutBuilderUX.php b/src/Element/LayoutBuilderUX.php | |
index 19ad7dd..664a6ef 100644 | |
--- a/src/Element/LayoutBuilderUX.php | |
+++ b/src/Element/LayoutBuilderUX.php | |
@@ -27,7 +27,7 @@ class LayoutBuilderUX implements TrustedCallbackInterface { | |
$section_label = $build['#attributes']['aria-label']; | |
$build['configure']['#title'] = t('<span class="visually-hidden">Configure @section</span>', ['@section' => $section_label]); | |
- $build['configure']['#url'] = Url::fromRoute('layout_builder.configure_section_form', $build['configure']['#url']->getRouteParameters()); | |
+ $build['configure']['#url'] = empty($build['configure']['#url']) ? NULL : Url::fromRoute('layout_builder.configure_section_form', $build['configure']['#url']->getRouteParameters()); | |
$build['remove']['#title'] = t('<span class="visually-hidden">Remove @section</span>', ['@section' => $section_label]); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment