Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHPMD: suppressed warning for unused parameters #2786

Closed
wants to merge 11 commits into from
Closed

PHPMD: suppressed warning for unused parameters #2786

wants to merge 11 commits into from

Conversation

sreichel
Copy link
Contributor

@sreichel sreichel commented Dec 6, 2022

Description (*)

Marked unused parameters to ignore them in PHPMD checks.

Related Pull Requests

  1. See PHPMD: added basic config #2771

Manual testing scenarios (*)

  1. vendor/bin/phpmd app/code/core/Mage/ text unusedcode | grep "UnusedFormalParameter"

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All automated tests passed successfully (all builds are green)
  • Add yourself to contributors list

@github-actions github-actions bot added Component: AdminNotification Relates to Mage_AdminNotification Component: Adminhtml Relates to Mage_Adminhtml Component: Admin Relates to Mage_Admin Component: Api PageRelates to Mage_Api Component: Api2 Relates to Mage_Api2 Component: Authorizenet Relates to Mage_Authorizenet Component: Backup Relates to Mage_Backup Component: Bundle Relates to Mage_Bundle Component: Captcha Relates to Mage_Captcha Component: Catalog Relates to Mage_Catalog Component: CatalogInventory Relates to Mage_CatalogInventory Component: CatalogRule Relates to Mage_CatalogRule Component: CatalogIndex Relates to Mage_CatalogIndex Component: CatalogSearch Relates to Mage_CatalogSearch Component: Centinel Relates to Mage_Centinel Component: Cms Relates to Mage_Cms Component: ConfigurableSwatches Relates to Mage_ConfigurableSwatches Component: Core Relates to Mage_Core Component: Cron Relates to Mage_Cron Component: Customer Relates to Mage_Customer Component: Dataflow Relates to Mage_Dataflow Component: Directory Relates to Mage_Directory Component: Downloadable Relates to Mage_Downloadable Component: Eav Relates to Mage_Eav labels Dec 6, 2022
@github-actions github-actions bot added Component: PaypalUk Relates to Mage_PaypalUk Component: ProductAlert Relates to Mage_ProductAlert Component: Reports Relates to Mage_Reports Component: Review Relates to Mage_Review Component: Rss Relates to Mage_Rss Component: Rule Relates to Mage_Rule Component: Sales Relates to Mage_Sales Component: SalesRule Relates to Mage_SalesRule Component: Sendfriend Relates to Mage_Sendfriend Component: Shipping Relates to Mage_Shipping Component: Sitemap Relates to Mage_Sitemap Component: Tax Relates to Mage_Tax Component: Usa Relates to Mage_Usa Component: Weee Relates to Mage_Weee Component: Wishlist Relates to Mage_Wishlist labels Dec 6, 2022
@sreichel sreichel mentioned this pull request Dec 6, 2022
12 tasks
@fballiano
Copy link
Contributor

question, why should we suppress the error instead of removing the parameters? cause they're used in inherited classes or something else?

@sreichel
Copy link
Contributor Author

sreichel commented Dec 6, 2022

Yes, the methods could be overwritten and method signature should not change.

# Conflicts:
#	app/code/core/Mage/Eav/Model/Entity/Attribute/Source/Abstract.php
#	app/code/core/Mage/Tax/Model/Sales/Total/Quote/Discount.php
#	app/code/core/Mage/Weee/Model/Total/Quote/Weee.php
#	phpstan.dist.baseline.neon
ADDISON74
ADDISON74 previously approved these changes Dec 23, 2022
# Conflicts:
#	phpstan.dist.baseline.neon
@sreichel sreichel closed this by deleting the head repository Jan 8, 2023
@ADDISON74 ADDISON74 reopened this Jan 9, 2023
@sreichel sreichel closed this Jan 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Admin Relates to Mage_Admin Component: Adminhtml Relates to Mage_Adminhtml Component: AdminNotification Relates to Mage_AdminNotification Component: Api PageRelates to Mage_Api Component: Api2 Relates to Mage_Api2 Component: Authorizenet Relates to Mage_Authorizenet Component: Backup Relates to Mage_Backup Component: Bundle Relates to Mage_Bundle Component: Captcha Relates to Mage_Captcha Component: Catalog Relates to Mage_Catalog Component: CatalogIndex Relates to Mage_CatalogIndex Component: CatalogInventory Relates to Mage_CatalogInventory Component: CatalogRule Relates to Mage_CatalogRule Component: CatalogSearch Relates to Mage_CatalogSearch Component: Centinel Relates to Mage_Centinel Component: Cms Relates to Mage_Cms Component: ConfigurableSwatches Relates to Mage_ConfigurableSwatches Component: Core Relates to Mage_Core Component: Cron Relates to Mage_Cron Component: Customer Relates to Mage_Customer Component: Dataflow Relates to Mage_Dataflow Component: Directory Relates to Mage_Directory Component: Downloadable Relates to Mage_Downloadable Component: Eav Relates to Mage_Eav Component: GoogleCheckout Relates to Mage_GoogleCheckout Component: ImportExport Relates to Mage_ImportExport Component: Index Relates to Mage_Index Component: Install Relates to Mage_Install Component: lib/Mage Relates to lib/Mage Component: lib/Varien Relates to lib/Varien Component: lib/* Relates to lib/* Component: Log Relates to Mage_Log Component: Media Relates to Mage_Media Component: Oauth Relates to Mage_Oauth Component: Page Relates to Mage_Page Component: Paygate Relates to Mage_Paygate Component: Payment Relates to Mage_Payment Component: PayPal Relates to Mage_Paypal Component: PaypalUk Relates to Mage_PaypalUk Component: ProductAlert Relates to Mage_ProductAlert Component: Reports Relates to Mage_Reports Component: Review Relates to Mage_Review Component: Rss Relates to Mage_Rss Component: Rule Relates to Mage_Rule Component: Sales Relates to Mage_Sales Component: SalesRule Relates to Mage_SalesRule Component: Sendfriend Relates to Mage_Sendfriend Component: Shipping Relates to Mage_Shipping Component: Sitemap Relates to Mage_Sitemap Component: Tax Relates to Mage_Tax Component: Usa Relates to Mage_Usa Component: Weee Relates to Mage_Weee Component: Wishlist Relates to Mage_Wishlist Don't forget this PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants