84% gbs-product-catalog

Code Review | GBS Product Catalog

WordPress plugin GBS Product Catalog scored84%from 54 tests.

About plugin

  • Plugin page: gbs-product-catalog
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.7
  • WordPress version: 6.3.1
  • First release: Dec 18, 2017
  • Latest release: Mar 31, 2021
  • Number of updates: 21
  • Update frequency: every 57.1 days
  • Top authors: gbsdeveloper (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /890 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.09MB] [CPU: ▼3.89ms] Passed 4 tests

A check of server-side resources used by GBS Product Catalog
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1039.43 ▼1.34
Dashboard /wp-admin3.40 ▲0.0944.94 ▼6.12
Posts /wp-admin/edit.php3.45 ▲0.0947.27 ▲0.27
Add New Post /wp-admin/post-new.php6.07 ▲0.1893.51 ▼8.36
Media Library /wp-admin/upload.php3.32 ▲0.0934.91 ▲1.53
Add New /wp-admin/post-new.php?post_type=gbspc-product6.0783.15
GBS Products /wp-admin/edit.php?post_type=gbspc-product3.3741.54
GBSPC Categories /wp-admin/edit-tags.php?taxonomy=gbspc-categories&post_type=gbspc-product3.3133.40
GBS Product Catalog /wp-admin/options-general.php?page=gbscatalog3.2932.40

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for GBS Product Catalog
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,928 ▲18214.05 ▼0.325.29 ▲3.2942.24 ▼0.65
Dashboard /wp-admin2,240 ▲495.84 ▼0.0497.18 ▼1.0940.89 ▼1.41
Posts /wp-admin/edit.php2,126 ▲402.00 ▼0.0239.92 ▲4.6433.67 ▼2.72
Add New Post /wp-admin/post-new.php1,563 ▲3423.28 ▲0.18640.50 ▲17.4855.42 ▲3.10
Media Library /wp-admin/upload.php1,422 ▲374.23 ▲0.0195.70 ▼5.2243.89 ▼4.39
Add New /wp-admin/post-new.php?post_type=gbspc-product6,19719.47846.4034.28
GBS Products /wp-admin/edit.php?post_type=gbspc-product1,1411.9530.2931.63
GBSPC Categories /wp-admin/edit-tags.php?taxonomy=gbspc-categories&post_type=gbspc-product1,2992.1424.8028.63
GBS Product Catalog /wp-admin/options-general.php?page=gbscatalog9752.0624.9926.79

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_header() in wp-content/plugins/gbs-product-catalog/includes/taxonomy-gbspc-categories.php:5

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 93% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: business catalog business portfolio, simple portfolio, products showcase, project portfolio, simple catalog...

gbs-product-catalog/gbs-catalog.php 85% from 13 tests

The main file in "GBS Product Catalog" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("gbs-product-catalog.php" instead of "gbs-catalog.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 172 characters long)

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
Success! There were no dangerous files found in this plugin624 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP55833442
CSS211182

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
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%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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