diff --git a/controllers/grid/users/author/AuthorGridHandler.php b/controllers/grid/users/author/AuthorGridHandler.php index a660b1dfd90..6ae01f2f394 100644 --- a/controllers/grid/users/author/AuthorGridHandler.php +++ b/controllers/grid/users/author/AuthorGridHandler.php @@ -22,6 +22,7 @@ use APP\core\Application; use APP\facades\Repo; use APP\notification\NotificationManager; +use APP\publication\Publication; use PKP\controllers\grid\feature\OrderGridItemsFeature; use PKP\controllers\grid\GridColumn; use PKP\controllers\grid\GridHandler; @@ -444,6 +445,8 @@ public function deleteAuthor($args, $request) $json = \PKP\db\DAO::getDataChangedEvent($authorId); $json->setGlobalEvent('authorsUpdated'); + $publication = $this->getPublication(); /** @var Publication $publication */ + $publication = Repo::publication()->edit($publication, []); return $json; } diff --git a/controllers/grid/users/author/form/PKPAuthorForm.php b/controllers/grid/users/author/form/PKPAuthorForm.php index 33301659133..2e9dad93a13 100644 --- a/controllers/grid/users/author/form/PKPAuthorForm.php +++ b/controllers/grid/users/author/form/PKPAuthorForm.php @@ -264,8 +264,10 @@ public function execute(...$functionParams) throw new Exception('Invalid primary contact ID. This author can not be a primary contact.'); } Repo::publication()->edit($publication, $params); + } else { + // Log an event when publication data is updated + $publication = Repo::publication()->edit($publication, []); } - return $authorId; } }