LB extractor plugin does not check if block_content is enabled
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3537028. -->
Reported by: [valthebald](https://www.drupal.org/user/239562)
Related to !772
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>In LbFieldExtractor::create()</p>
<pre><span style="color: #000000"><span style="color: #0000BB"><?php<br> $instance</span><span style="color: #007700">-></span><span style="color: #0000BB">blockStorage </span><span style="color: #007700">= </span><span style="color: #0000BB">$container</span><span style="color: #007700">-></span><span style="color: #0000BB">get</span><span style="color: #007700">(</span><span style="color: #DD0000">'entity_type.manager'</span><span style="color: #007700">)?-></span><span style="color: #0000BB">getStorage</span><span style="color: #007700">(</span><span style="color: #DD0000">'block_content'</span><span style="color: #007700">);<br></span><span style="color: #0000BB">?></span></span></pre><p>which fails if block_content module is not enabled</p>
<h4 id="summary-steps-reproduce">Steps to reproduce (required for bugs, but not feature requests)</h4>
<p>Enable the following modules:</p>
<p>* Layout builder<br>
* AI translate<br>
* Content translation</p>
<p>Go to node/<nid>/translate and try to translate a node</nid></p>
<p>This results in error</p>
<h3 id="summary-proposed-resolution">Proposed resolution</h3>
<p>Wrap assignment with try/catch, mark plugin as unusable if block_content is not enabled</p>
issue