stream
stream copied to clipboard
PHP Error accessing user in wp cli triggered update
trafficstars
Bug Report
Expected Behavior
The user object would be checked before attempting to use any fields or values.
Actual Behavior
Get user is used to get a user, but false is returned because the user doesn't exist. This results in the error:
Warning: Attempt to read property "user login" on bool in /code/wp-content/plugins/stream/alerts/class-alert-type-ifttt.php on line 232
This may occur in other alerts, but this is the one currently triggering the problem.
Steps to Reproduce the Problem
- trigger an alert where the user ID does not return a valid user
- see the warning
Screenshots
Drag and drop screenshots in this area that help illustrate the problem.
System Information
This was noted when running a WPCLI command so the browser and OS are not applicable.
- Stream plugin version: 3.9.3
- WordPress version: 6.2.2
- PHP version: 8.0
- Browser: NA
- Computer operating system: NA