Skip to content

Conversation

@ntaylor-86
Copy link
Contributor

This PR adds a null safe operator to app/Console/Kernal.php.

I was having the same issue as #16815 on a fresh install of Snipe-IT using docker.

The schedule is trying to access alerts_enabled from the Setting model but on a fresh install it doesn't exist yet.

Updates the Kernel to use the null-safe operator
when accessing the alerts_enabled setting. This prevents
a potential error if the settings object is null.
@ntaylor-86 ntaylor-86 requested a review from snipe as a code owner May 5, 2025 23:56
@snipe snipe changed the title Fixed #16815: Avoids potential error when alerts table is empty Fixed #16815: Avoids potential error when settings table is empty May 5, 2025
@snipe snipe merged commit 36f3834 into grokability:develop May 5, 2025
9 checks passed
@snipe
Copy link
Member

snipe commented May 6, 2025

Awesome, ty!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants