Invoke "mailpoet_scripts_admin_before" from the asset controller

[MAILPOET-5118]
This commit is contained in:
Jan Jakes
2023-09-28 15:31:31 +02:00
committed by Aschepikov
parent 2a676353aa
commit ed76bbf3d6
3 changed files with 12 additions and 2 deletions

View File

@@ -109,6 +109,10 @@ class AssetsController {
]
);
$this->wp->wpSetScriptTranslations('mailpoet_admin', 'mailpoet');
if ($this->wp->didAction('mailpoet_scripts_admin_before') === 0) {
$this->wp->doAction('mailpoet_scripts_admin_before');
}
}
private function getScriptUrl(string $name): string {