84% wc-rte-rodonaves-shipping

Code Review | Paulo Cezario - RTE Rodonaves shipping for WooCommerce

WordPress plugin Paulo Cezario - RTE Rodonaves shipping for WooCommerce scored 84% from 54 tests.

About plugin

  • Plugin page: wc-rte-rodonaves-...
  • Plugin version: 0.2.0
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.2
  • WordPress version: 6.3.1
  • First release: Jan 12, 2023
  • Latest release: May 19, 2023
  • Number of updates: 6
  • Update frequency: every 23.8 days
  • Top authors: phscezario (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 461 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▼0.18MB] [CPU: ▼16.98ms] Passed 4 tests

An overview of server-side resources used by Paulo Cezario - RTE Rodonaves shipping for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.39 ▼0.0722.61 ▼16.13
Dashboard /wp-admin3.20 ▼0.1030.01 ▼16.51
Posts /wp-admin/edit.php3.27 ▼0.0934.96 ▼13.51
Add New Post /wp-admin/post-new.php5.44 ▼0.4465.47 ▼21.77
Media Library /wp-admin/upload.php3.21 ▼0.0229.30 ▼4.77

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Paulo Cezario - RTE Rodonaves shipping for WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,467 ▼27913.52 ▼0.860.47 ▼1.3815.54 ▼28.69
Dashboard /wp-admin2,208 ▲205.85 ▲0.93111.77 ▲6.9743.01 ▼1.78
Posts /wp-admin/edit.php2,091 ▲22.01 ▼0.0141.04 ▲3.8534.36 ▲0.77
Add New Post /wp-admin/post-new.php1,517 ▼1623.57 ▲0.37653.46 ▼27.1469.14 ▲8.88
Media Library /wp-admin/upload.php1,393 ▲24.23 ▼0.0299.20 ▼5.2844.05 ▼1.79

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
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 5× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wc-rte-rodonaves-shipping/views/wc-rte-shipping-product-page.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wc-rte-rodonaves-shipping/views/wc-rte-shipping-extra-meta-admin.php:38
    • > PHP Notice
      Undefined variable: product in wp-content/plugins/wc-rte-rodonaves-shipping/views/wc-rte-shipping-extra-meta-admin.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wc-rte-rodonaves-shipping/views/wc-rte-shipping-user-order-infos.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wc-rte-rodonaves-shipping/views/wc-rte-shipping-cart-page.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
4 plugin tags: rte rodonaves, shipping, woocommerce, delivery

wc-rte-rodonaves-shipping/wc-rte-rodonaves-shipping.php Passed 13 tests

The main PHP file in "Paulo Cezario - RTE Rodonaves shipping for WooCommerce" ver. 0.2.0 adds more information about the plugin and also serves as the entry point for this plugin
50 characters long description:
Plugin add RTE Rodonaves Shippging to WooCommerce.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin1,175 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP913874700
JavaScript2291211
PO File16063152
Markdown139057
CSS30055

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity13.33
▷ Minimum class complexity2.00
▷ Maximum class complexity21.00
Average method complexity2.85
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods20
▷ Static methods420.00%
▷ Public methods1260.00%
▷ Protected methods735.00%
▷ Private methods15.00%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin