Skip to content

Conversation

@Rabbittoly
Copy link

Fixes #000.

Describe your approach and how it fixes the issue.

Checklist

  • Project documentation has been updated to reflect the changes in this pull request, if applicable.
  • I have tested the changes in the local development environment (see contributing.md).
  • I have added phpunit tests.

Release Changelog

  • Fix: Describe a bug fix included in this release.
  • New: Describe a new feature in this release.

Release Checklist

  • This pull request is to the master branch.
  • Release version follows semantic versioning. Does it include breaking changes?
  • Update changelog in readme.txt.
  • Bump version in stream.php.
  • Bump Stable tag in readme.txt.
  • Bump version in classes/class-plugin.php.
  • Draft a release on GitHub.

Change [ ] to [x] to mark the items as done.

Prevents PHP Warning when running WP-CLI as non-existent system user.
The posix_getpwuid() function returns false if the UID doesn't exist,
which caused array offset errors when trying to access the 'name' key.

Added is_array() check before accessing user_info array to safely
handle cases where posix_getpwuid() returns false.

Fixes xwp#1783
Issue xwp#1701: Remove sprintf() wrapper to prevent vsprintf format
specifier errors. When activity content contains % characters, the
vsprintf() call in Log::log() was failing with 'Unknown format specifier'
errors. Moved dynamic content to args array for proper interpolation.

Fixed in methods:
- callback_bp_activity_deleted_activities()
- callback_bp_activity_mark_as_spam()
- callback_bp_activity_mark_as_ham()
- callback_bp_activity_admin_edit_after()

Issue xwp#1728: Replace non-existent bp_current_user_can_moderate()
function with proper bp_current_user_can('bp_moderate') capability
check. Added function_exists() guard to prevent fatal errors when
BuddyPress functions are not available.

Fixes xwp#1701, xwp#1728
Prevents 'Cannot unset string offsets' error when widget options
are unexpectedly strings instead of arrays. This can happen when
widget data becomes corrupted or when third-party plugins modify
option values incorrectly.

Added is_array() and isset() checks before attempting to unset
the '_multiwidget' key from both new_value and old_value arrays.

Fixes xwp#1651
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