lighthouse improvements

This commit is contained in:
Dennis Eichhorn 2023-09-26 20:49:43 +00:00
parent ff8b7b7bf8
commit 368b99212c

View File

@ -48,10 +48,12 @@ final class BackendController extends Controller
public function setUpDrawEditor(RequestAbstract $request, ResponseAbstract $response, mixed $data = null) : void
{
/** @var \phpOMS\Model\Html\Head $head */
$head = $response->data['Content']->head;
$head->addAsset(AssetType::JSLATE, 'Modules/Draw/Controller.js?v=1.0.0');
$head->addAsset(AssetType::JSLATE, 'Modules/Draw/Models/DrawType.js?v=1.0.0');
$head->addAsset(AssetType::JSLATE, 'Modules/Draw/Models/Editor.js?v=1.0.0');
$head = $response->data['Content']->head;
$nonce = $this->app->appSettings->getOption('script-nonce');
$head->addAsset(AssetType::JSLATE, 'Modules/Draw/Controller.js?v=1.0.0', ['nonce' => $nonce]);
$head->addAsset(AssetType::JSLATE, 'Modules/Draw/Models/DrawType.js?v=1.0.0', ['nonce' => $nonce]);
$head->addAsset(AssetType::JSLATE, 'Modules/Draw/Models/Editor.js?v=1.0.0', ['nonce' => $nonce]);
}
/**