89% restrict-woocommerce-reports-status

Code Review | Restrict WooCommerce Reports Status

WordPress plugin Restrict WooCommerce Reports Status scored89%from 54 tests.

About plugin

  • Plugin page: restrict-woocomme...
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-4.9.5
  • WordPress version: 6.3.1
  • First release: May 12, 2018
  • Latest release: May 12, 2018
  • Number of updates: 7
  • Update frequency: N/A
  • Top authors: Amgnando (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /530 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼6.42ms] Passed 4 tests

An overview of server-side resources used by Restrict WooCommerce Reports Status
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0142.42 ▲6.06
Dashboard /wp-admin3.31 ▼0.0347.64 ▼12.82
Posts /wp-admin/edit.php3.37 ▲0.0151.69 ▲3.27
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.43 ▼14.19
Media Library /wp-admin/upload.php3.24 ▲0.0135.14 ▼1.92

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
db_upgraded
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Restrict WooCommerce Reports Status
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.28 ▼0.251.75 ▲0.0743.93 ▲5.31
Dashboard /wp-admin2,195 ▲145.57 ▼0.0891.27 ▼6.5452.99 ▲9.30
Posts /wp-admin/edit.php2,103 ▲31.97 ▲0.0239.57 ▼1.4936.55 ▼1.19
Add New Post /wp-admin/post-new.php1,531 ▲323.28 ▲0.01687.10 ▼8.6654.52 ▼12.47
Media Library /wp-admin/upload.php1,400 ▼34.18 ▼0.0397.91 ▼3.5343.85 ▼3.99

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Screenshots: Please add images for these screenshots: #1 (WooCommerce default report), #2 (WooCommerce real report)
You can look at the official readme.txt

restrict-woocommerce-reports-status/restrict-woocommerce-reports-status.php 92% from 13 tests

The entry point to "Restrict WooCommerce Reports Status" version 1.0.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Requires at least: The required version number did not match the one declared in readme.txt ("4.0" instead of "3.0.0")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin52 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PO File14627
PHP1104525

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods125.00%
▷ Public methods375.00%
▷ Protected methods00.00%
▷ Private methods125.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.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
No PNG files were detected