90% favepay-for-woocommerce

Code Review | FavePay for WooCommerce

WordPress plugin FavePay for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: favepay-for-wooco...
  • Plugin version: 1.0.11
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.8
  • WordPress version: 6.3.1
  • First release: Aug 4, 2021
  • Latest release: May 18, 2022
  • Number of updates: 23
  • Update frequency: every 12.6 days
  • Top authors: favemy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

80+ active /3,542 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.09MB] [CPU: ▼6.08ms] Passed 4 tests

Server-side resources used by FavePay for WooCommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1041.91 ▼6.07
Dashboard /wp-admin3.40 ▲0.0952.02 ▼0.56
Posts /wp-admin/edit.php3.51 ▲0.1547.68 ▼12.87
Add New Post /wp-admin/post-new.php5.98 ▲0.0991.79 ▼4.82
Media Library /wp-admin/upload.php3.32 ▲0.0937.64 ▲0.73

Server storage [IO: ▲0.06MB] [DB: ▲0.00MB] Passed 3 tests

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 24 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
favepay_wc_unique_site_id

Browser metrics Passed 4 tests

This is an overview of browser requirements for FavePay for WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,914 ▲15313.54 ▼0.9510.62 ▲8.7578.62 ▲31.54
Dashboard /wp-admin2,210 ▲335.62 ▼0.0991.39 ▼5.6941.77 ▲2.14
Posts /wp-admin/edit.php2,112 ▲121.97 ▲0.0338.06 ▼3.8542.65 ▲5.86
Add New Post /wp-admin/post-new.php1,537 ▲1123.58 ▲2.58660.84 ▼48.9364.65 ▲17.55
Media Library /wp-admin/upload.php1,403 ▼04.18 ▼0.00100.43 ▼5.4743.51 ▼2.51

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options detected upon uninstall: 7 options
    • favepay_wc_unique_site_id
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
3 plugin tags: payment, favepay, woocommerce

favepay-for-woocommerce/favepay-wc.php 92% from 13 tests

The main PHP file in "FavePay for WooCommerce" ver. 1.0.11 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("favepay-for-woocommerce.php" instead of "favepay-wc.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected973 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP13372141924
SVG10148
CSS1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity14.00
▷ Minimum class complexity1.00
▷ Maximum class complexity80.00
Average method complexity3.25
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits1
Classes8
▷ Abstract classes112.50%
▷ Concrete classes787.50%
▷ Final classes00.00%
Methods52
▷ Static methods815.38%
▷ Public methods3363.46%
▷ Protected methods47.69%
▷ Private methods1528.85%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants675.00%
▷ Class constants225.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin