100% msrp-for-woocommerce

Code Review | MSRP (List Price/RRP) for WooCommerce

WordPress plugin MSRP (List Price/RRP) for WooCommerce scored 100% from 54 tests.

About plugin

  • Plugin page: msrp-for-woocommerce
  • Plugin version: 1.7.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.9
  • WordPress version: 5.9.2
  • First release: May 7, 2018
  • Latest release: Mar 19, 2022
  • Number of updates: 65
  • Update frequency: every 21.7 days
  • Top authors: algoritmika (58.46%)omardabbas (43.08%)

Code review

54 tests

User reviews

8 reviews

Install metrics

200+ active / 8,022 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.01MB] [CPU: ▼305.65ms] Passed 4 tests

Server-side resources used by MSRP (List Price/RRP) for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0252.20 ▼1.07
Dashboard /wp-admin3.43 ▲0.0235.88 ▼0.14
Posts /wp-admin/edit.php3.66 ▲0.0237.08 ▼3.61
Add New Post /wp-admin/post-new.php6.90 ▼0.0795.11 ▼1,216.73
Media Library /wp-admin/upload.php3.31 ▲0.0222.66 ▼1.20

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 12 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by MSRP (List Price/RRP) for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,795 ▲7315.89 ▲0.356.50 ▲0.983.01 ▲0.55
Dashboard /wp-admin2,892 ▲316.09 ▼0.11117.67 ▼16.94153.88 ▼11.02
Posts /wp-admin/edit.php2,688 ▼33.23 ▲0.0163.06 ▼5.79139.82 ▼8.34
Add New Post /wp-admin/post-new.php1,668 ▼2818.14 ▼3.14410.59 ▼26.77157.74 ▼3.34
Media Library /wp-admin/upload.php1,698 ▼35.49 ▼0.01140.77 ▼6.27188.72 ▲5.82

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed: You can take inspiration from this readme.txt

msrp-for-woocommerce/msrp-for-woocommerce.php Passed 13 tests

The main file in "MSRP (List Price/RRP) for WooCommerce" v. 1.7.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
45 characters long description:
Save and display product MSRP in WooCommerce.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected1,708 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP101857301,708

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.61
Average class complexity32.89
▷ Minimum class complexity1.00
▷ Maximum class complexity187.00
Average method complexity4.63
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes111.11%
Methods79
▷ Static methods11.27%
▷ Public methods79100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin