diff --git a/CHANGELOG-v3.md b/CHANGELOG-v3.md index 17caa0b8cba..6044dc48235 100644 --- a/CHANGELOG-v3.md +++ b/CHANGELOG-v3.md @@ -1,5 +1,11 @@ # Release Notes for Craft CMS 3.x +## Unreleased + +### Fixed +- Fixed an error that occurred when deleting an entry from the Edit Entry page. ([#3372](https://github.com/craftcms/cms/issues/3372)) + + ## 3.0.27 - 2018-10-11 ### Added diff --git a/src/controllers/EntriesController.php b/src/controllers/EntriesController.php index ff5ab387a32..c7d72f46e14 100644 --- a/src/controllers/EntriesController.php +++ b/src/controllers/EntriesController.php @@ -605,7 +605,7 @@ public function actionDeleteEntry() $request = Craft::$app->getRequest(); $entryId = $request->getRequiredBodyParam('entryId'); $siteId = $request->getBodyParam('siteId'); - $entry = $request->getEntryById($entryId, $siteId); + $entry = Craft::$app->getEntries()->getEntryById($entryId, $siteId); if (!$entry) { throw new NotFoundHttpException('Entry not found');