Skip to content

Commit

Permalink
[BUGFIX] Replace deprecated EventManager::getListeners with getAllLis…
Browse files Browse the repository at this point in the history
…teners
  • Loading branch information
vertexvaar committed Nov 7, 2023
1 parent e75c1d6 commit 900b40e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Classes/Utility/DatabaseUtility.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public static function buildForeignDatabaseConnection(): ?Connection

try {
$foreignConnection = $connectionPool->getConnectionByName('in2publish_foreign');
foreach ($foreignConnection->getEventManager()->getListeners() as $event => $listeners) {
foreach ($foreignConnection->getEventManager()->getAllListeners() as $event => $listeners) {
foreach ($listeners as $listener) {
$foreignConnection->getEventManager()->removeEventListener($event, $listener);
}
Expand Down

0 comments on commit 900b40e

Please sign in to comment.