Verified Commit 68ebeccd authored by Cyril Vazquez's avatar Cyril Vazquez
Browse files

Fix count on empty property (awaiting array)

parent ebad080f
Pipeline #6965 canceled with stages
......@@ -350,7 +350,7 @@ trait archiveEntryTrait
// Set archive name when mono document
if (empty($archive->archiveName)) {
if (count($archive->digitalResources)) {
if (is_array($archive->digitalResources) && count($archive->digitalResources)) {
foreach ($archive->digitalResources as $digitalResource) {
if (isset($digitalResource->fileName)) {
$archive->archiveName = pathinfo($digitalResource->fileName, \PATHINFO_FILENAME);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment