10% growpro-widgets

Code Review | GrowPro widgets

WordPress plugin GrowPro widgets scored 10% from 54 tests.

About plugin

  • Plugin page: growpro-widgets
  • Plugin version: 2.0.8
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-5.3
  • WordPress version: 5.8.1
  • First release: Feb 10, 2020
  • Latest release: Apr 10, 2020
  • Number of updates: 17
  • Update frequency: every 3.8 days
  • Top authors: growpro (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 312 total downloads

Benchmarks

Plugin footprint 75% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
You still need to fix the following installer errors
  • The plugin cannot be installed
    • > Notice in wp-content/plugins/growpro-widgets/growpro-widgets.php+38
    Undefined offset: 0

Server metrics [RAM: ▲0.02MB] [CPU: ▼138.01ms] Passed 4 tests

Analyzing server-side resources used by GrowPro widgets
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.86 ▲0.1438.12 ▲13.56
Dashboard /wp-admin3.08 ▲0.0247.56 ▲1.86
Posts /wp-admin/edit.php3.13 ▲0.0247.93 ▲2.49
Add New Post /wp-admin/post-new.php5.44 ▲0.0195.76 ▼558.83
Media Library /wp-admin/upload.php3.02 ▲0.0230.78 ▲2.43
Generar widgets /wp-admin/admin.php?page=growpro-widgets/includes/gpw-first-acp-page.php2.9927.56
Ajustes /wp-admin/admin.php?page=growpro-widgets/includes/gpw-setting.php3.0030.81
Generar links /wp-admin/admin.php?page=growpro-widgets/includes/gpw-link-gen-page.php2.9929.77

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 11 new files
Database: 1 new table, no new options
New tables
wp_gpw_setting

Browser metrics Passed 4 tests

An overview of browser requirements for GrowPro widgets
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,855 ▲27316.23 ▲0.6113.00 ▲3.0552.66 ▼1.30
Dashboard /wp-admin3,030 ▲996.13 ▲0.16143.51 ▼10.53114.83 ▼0.46
Posts /wp-admin/edit.php2,777 ▲382.70 ▲0.0170.13 ▲3.0891.94 ▼0.74
Add New Post /wp-admin/post-new.php1,899 ▲22719.23 ▲0.14378.73 ▼2.12106.66 ▼7.16
Media Library /wp-admin/upload.php1,848 ▲415.00 ▼0.01150.77 ▼5.52119.04 ▼6.47
Generar widgets /wp-admin/admin.php?page=growpro-widgets/includes/gpw-first-acp-page.php1,0632.0956.9668.77
Ajustes /wp-admin/admin.php?page=growpro-widgets/includes/gpw-setting.php1,1232.0550.2167.69
Generar links /wp-admin/admin.php?page=growpro-widgets/includes/gpw-link-gen-page.php1,0602.0554.5162.46

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
  • 7× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/growpro-widgets/growpro-widgets.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/growpro-widgets/includes/gpw-setting.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/growpro-widgets/includes/gpw-header.php:3
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/growpro-widgets/uninstall.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/growpro-widgets/includes/gpw-first-acp-page.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/growpro-widgets/includes/gpw-link-gen-page.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/growpro-widgets/includes/gpw-functions.php:11

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
  • Contributors: The plugin contributors field is not present
You can take inspiration from this readme.txt

growpro-widgets/growpro-widgets.php Passed 13 tests

The principal PHP file in "GrowPro widgets" v. 2.0.8 is loaded by WordPress automatically on each request
44 characters long description:
Generador de widgets para GrowPro Experience

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin258 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP74027186
CSS10068
JavaScript1614

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
includes/css/growpro-logo.png4.30KB3.53KB▼ 17.86%