drop php7.3 support, make use of 7.4 features

This commit is contained in:
Shish
2021-03-14 23:43:50 +00:00
parent c558ee3bdb
commit 77f7121e26
296 changed files with 1571 additions and 2039 deletions

View File

@ -3,7 +3,7 @@
class RandomImage extends Extension
{
/** @var RandomImageTheme */
protected $theme;
protected ?Themelet $theme;
public function onPageRequest(PageRequestEvent $event)
{
@ -28,9 +28,7 @@ class RandomImage extends Extension
}
if ($action === "download") {
if (!is_null($image)) {
send_event(new ImageDownloadingEvent($image, $image->get_image_filename(), $image->get_mime()));
}
send_event(new ImageDownloadingEvent($image, $image->get_image_filename(), $image->get_mime()));
} elseif ($action === "view") {
send_event(new DisplayingImageEvent($image));
} elseif ($action === "widget") {