fix passing nulll to parameter (thx @brol )

This commit is contained in:
Jean-Christian Paul Denis 2023-01-02 09:57:04 +01:00 committed by GitHub
parent a1c90350d1
commit d815805fff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,7 +52,7 @@ class shortArchivesWidgets
} }
$active_year = null; $active_year = null;
if ((dcCore::app()->url->type == 'archive') && preg_match('`^/([0-9]{4})/([0-9]{2})$`', dcCore::app()->url->args, $matches)) { if ((dcCore::app()->url->type == 'archive') && preg_match('`^/([0-9]{4})/([0-9]{2})$`', (string) dcCore::app()->url->args, $matches)) {
$active_year = $matches[1]; $active_year = $matches[1];
} }