Change type definition on notify_users to allow for null input (#34)

Signed-off-by: Sören Wünsch <soeren.wrede@parshipgroup.com>
Signed-off-by: Topher DeRosia <topher@mediaforge.pro>
Signed-off-by: Colin Stewart <79332690+costdev@users.noreply.github.com>
Co-authored-by: Sören Wünsch <soerenwrede@gmail.com>
Co-authored-by: Colin Stewart <79332690+costdev@users.noreply.github.com>
Co-authored-by: Joost de Valk <joost@altha.nl>
This commit is contained in:
Topher DeRosia 2025-06-17 13:04:55 -04:00 committed by GitHub
parent 24d7e9e49b
commit d2f2df6787
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -18,10 +18,10 @@ function bootstrap() {
/** /**
* Add a notification to the site footer about FAIR/AspirePress. * Add a notification to the site footer about FAIR/AspirePress.
* *
* @param string $content The current version or update notification. * @param string|null $content The current version or update notification.
* @return string * @return string
*/ */
function notify_users( string $content = '' ) : string { function notify_users( ?string $content = null ) : string {
$message = sprintf( $message = sprintf(
// translators: 1) Fair PM URL, 2) AspirePress URL. // translators: 1) Fair PM URL, 2) AspirePress URL.
__( 'Updates served from the <a href="%1$s">FAIR Package Manager</a> and <a href="%2$s">AspirePress</a>', 'fair' ), __( 'Updates served from the <a href="%1$s">FAIR Package Manager</a> and <a href="%2$s">AspirePress</a>', 'fair' ),