Sidebar is broken on missing translations
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3031044. -->
Reported by: [arpad.rozsa](https://www.drupal.org/user/3509607)
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>When I'm viewing a node for example in German and the node wasn't yet translated to German, I get the English version as a fallback. In this case the sidebar won't open. The problem is with the following <code>$entity = $entity->getTranslation($language->getId());</code> in line #145 inside the <code>sideBar()</code> method.</p>
<h3 id="summary-proposed-resolution">Proposed resolution</h3>
<p>Wrap the line, mentioned above, into an <code>if</code> and check if the entity has been translated into the current language.</p>
issue