Skip to content

Ensure settings is an array#1235

Open
girishpanchal30 wants to merge 2 commits into
developmentfrom
bugfix/1232
Open

Ensure settings is an array#1235
girishpanchal30 wants to merge 2 commits into
developmentfrom
bugfix/1232

Conversation

@girishpanchal30
Copy link
Copy Markdown
Contributor

Summary

Validate that the settings are an array to prevent automatic conversion of false to an array in PHP 8.1+, which causes deprecation warnings.

Check before Pull Request is ready:

Closes #1232

@girishpanchal30 girishpanchal30 requested a review from Copilot May 22, 2026 10:20
@girishpanchal30 girishpanchal30 added the pr-checklist-skip Allow this Pull Request to skip checklist. label May 22, 2026
@pirate-bot pirate-bot added the pr-checklist-complete The Pull Request checklist is complete. (automatic label) label May 22, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to prevent PHP 8.1+ deprecation warnings caused by writing into $settings[...] when $settings is false (due to feedzy_get_settings filters returning non-arrays), by normalizing $settings to an array before assigning nested keys.

Changes:

  • Adds an is_array() guard to ensure $settings is an array prior to setting general tab options.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread includes/admin/feedzy-rss-feeds-admin.php Outdated
Comment thread includes/admin/feedzy-rss-feeds-admin.php Outdated
@pirate-bot
Copy link
Copy Markdown
Contributor

pirate-bot commented May 22, 2026

Plugin build for 6f475ae is ready 🛎️!

Note

You can preview the changes in the Playground

@girishpanchal30 girishpanchal30 changed the title fix: ensure settings is an array Ensure settings is an array May 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-checklist-complete The Pull Request checklist is complete. (automatic label) pr-checklist-skip Allow this Pull Request to skip checklist.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants