78% geargag-toolkit

Code Review | GearGag Toolkit

WordPress plugin GearGag Toolkit scored78%from 54 tests.

About plugin

  • Plugin page: geargag-toolkit
  • Plugin version: 2.5.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2.0+
  • WordPress version: 6.3.1
  • First release: Nov 23, 2019
  • Latest release: Nov 19, 2020
  • Number of updates: 16
  • Update frequency: every 22.7 days
  • Top authors: geargag (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,005 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▼0.46MB] [CPU: ▼17.31ms] Passed 4 tests

A check of server-side resources used by GearGag Toolkit
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.68 ▲0.2240.99 ▲1.61
Dashboard /wp-admin3.58 ▲0.2350.77 ▼10.53
Posts /wp-admin/edit.php3.63 ▲0.2746.11 ▼0.45
Add New Post /wp-admin/post-new.php3.40 ▼2.4836.67 ▼59.87
Media Library /wp-admin/upload.php3.44 ▲0.2136.94 ▲3.85
Batch Delete /wp-admin/edit.php?post_type=product&page=batch_delete_products3.2824.31

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 34 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

GearGag Toolkit: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,792 ▲4614.35 ▲0.001.70 ▲0.1444.00 ▲2.73
Dashboard /wp-admin2,201 ▲245.62 ▼0.0591.07 ▲1.7143.94 ▼0.65
Posts /wp-admin/edit.php2,103 ▼01.98 ▲0.0333.60 ▼7.0135.09 ▼0.28
Add New Post /wp-admin/post-new.php1,529 ▲123.38 ▲0.60653.33 ▲18.5054.92 ▼5.84
Media Library /wp-admin/upload.php1,403 ▲34.21 ▲0.0392.92 ▼4.4441.58 ▲0.26
Batch Delete /wp-admin/edit.php?post_type=product&page=batch_delete_products280.420.093.87

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

Smoke tests 50% from 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 50% from 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
Please fix the following
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Interface 'GearGag_Toolkit\\tools\\contracts\\Bootable' not found in wp-content/plugins/geargag-toolkit/Woo_Gallery.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'GearGag_Toolkit\\tools\\contracts\\Bootable' not found in wp-content/plugins/geargag-toolkit/tools/contracts/Enqueueable.php:10

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There are user-side issues you should fix
    • > GET request to /wp-admin/edit.php?post_type=product&page=batch_delete_products
    • > Network (severe)
    wp-admin/edit.php?post_type=product&page=batch_delete_products - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Requires at least: Invalid version format
  • Tested up to: Invalid version format
You can look at the official readme.txt

geargag-toolkit/index.php 92% from 13 tests

Analyzing the main PHP file in "GearGag Toolkit" version 2.5.0
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("geargag-toolkit.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin2,367 lines of code in 31 files:
LanguageFilesBlank linesComment linesLines of code
PHP294713172,355
JSON20012

PHP code Passed 2 tests

An overview of 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.31
Average class complexity9.17
▷ Minimum class complexity1.00
▷ Maximum class complexity44.00
Average method complexity2.88
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces5
Interfaces6
Traits0
Classes18
▷ Abstract classes211.11%
▷ Concrete classes1688.89%
▷ Final classes16.25%
Methods110
▷ Static methods1513.64%
▷ Public methods10393.64%
▷ Protected methods32.73%
▷ Private methods43.64%
Functions13
▷ Named functions1184.62%
▷ Anonymous functions215.38%
Constants18
▷ Global constants1266.67%
▷ Class constants633.33%
▷ Public constants6100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

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