UpdateStatus throws warning when there are no e-mail addresses set

Created on 2 September 2023, 10 months ago

Problem/Motivation

The Update Status plugin checks for e-mail addresses. When no addresses are set, it logs a warning, because the final mail check doesn't test if there's a result.

Warning: foreach() argument must be of type array|object, null given in Drupal\vitals_extra\Plugin\VitalsCheck\UpdateStatus->getData() (regel 42 van /app/www/modules/contrib/vitals_extra/src/Plugin/VitalsCheck/UpdateStatus.php)

Steps to reproduce

Enable the Update status plugin, check the vitals endpoint, then check the logs for the PHP warning.

Proposed resolution

Add extra test on last check.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡§πŸ‡ͺBelgium tijsdeboeck Antwerp πŸ‡§πŸ‡ͺ πŸ‡ͺπŸ‡Ί 🌎

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024