diff --git a/system/src/Grav/Common/Flex/Types/Pages/PageObject.php b/system/src/Grav/Common/Flex/Types/Pages/PageObject.php index 63f4cd4d48..933a00a32b 100644 --- a/system/src/Grav/Common/Flex/Types/Pages/PageObject.php +++ b/system/src/Grav/Common/Flex/Types/Pages/PageObject.php @@ -308,7 +308,7 @@ public function delete() // Backwards compatibility with older plugins. $fireEvents = $this->isAdminSite() && $this->getFlexDirectory()->getConfig('object.compat.events', true); if ($fireEvents) { - $this->grav->fireEvent('onAdminAfterDelete', new Event(['object' => $this])); + $this->getContainer()->fireEvent('onAdminAfterDelete', new Event(['object' => $this])); } return $result;