diff --git a/src/Controller/Admin/EbookController.php b/src/Controller/Admin/EbookController.php index 675e67b..dd49590 100644 --- a/src/Controller/Admin/EbookController.php +++ b/src/Controller/Admin/EbookController.php @@ -125,8 +125,8 @@ public function createAction() : []; $params['resource_ids'] = $resourceIds; // Manage Omeka with or without pull request #1260 (with or without - // param batch_action), so check $resourceIds. - $selectAll = $params['batch_action'] ? $params['batch_action'] === 'ebook-all' : empty($resourceIds); + // param batch_action), so check $resourceIds in all cases. + $selectAll = $params['batch_action'] ? $params['batch_action'] === 'ebook-all' : (empty($resourceIds) || (bool) $params['ebook_all']); $params['batch_action'] = $selectAll ? 'ebook-all' : 'ebook-selected'; $controllers = [