Skip to content

Commit

Permalink
Issue #3062446 by a.qala: duplicate if statements in "MenuLinkContent…
Browse files Browse the repository at this point in the history
….php" on line 151 and 156 - Code Improvement in "Custom Menu Links" module

(cherry picked from commit f3d48c2cd8eb86f49590869673e9ec2b4400ca89)
  • Loading branch information
xjm committed May 19, 2020
1 parent 73bf939 commit a8c22cd
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions modules/menu_link_content/src/Plugin/Menu/MenuLinkContent.php
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,6 @@ protected function getEntity() {
// Fallback to the loading by the UUID.
$uuid = $this->getUuid();
$entity = $this->entityRepository->loadEntityByUuid('menu_link_content', $uuid);
}
if (!$entity) {
throw new PluginException("Entity not found through the menu link plugin definition and could not fallback on UUID '$uuid'");
}
// Clone the entity object to avoid tampering with the static cache.
Expand Down

0 comments on commit a8c22cd

Please sign in to comment.