84% category-popular-tags

Code Review | Category Popular Tags

WordPress plugin Category Popular Tags scored84%from 54 tests.

About plugin

  • Plugin page: category-popular-...
  • Plugin version: 1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.2.4
  • WordPress version: 6.3.1
  • First release: Oct 19, 2019
  • Latest release: Oct 19, 2019
  • Number of updates: 6
  • Update frequency: every 0.3 days
  • Top authors: kusimo (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /487 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
Install script ran successfully

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

Analyzing server-side resources used by Category Popular Tags
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.39 ▼0.0726.92 ▼17.81
Dashboard /wp-admin3.32 ▲0.0245.03 ▼3.53
Posts /wp-admin/edit.php3.37 ▲0.0255.26 ▲7.87
Add New Post /wp-admin/post-new.php5.90 ▲0.0283.23 ▼8.06
Media Library /wp-admin/upload.php3.24 ▲0.0236.96 ▲1.20
Category Tags /wp-admin/options-general.php?page=pct-setting-admin3.1827.18

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

Category Popular Tags: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,831 ▲9613.27 ▼1.314.98 ▲3.2147.48 ▼1.35
Dashboard /wp-admin2,204 ▲135.83 ▼0.0798.59 ▼16.9539.30 ▼5.23
Posts /wp-admin/edit.php2,093 ▲12.02 ▲0.0234.84 ▼1.4730.68 ▼3.20
Add New Post /wp-admin/post-new.php1,536 ▲323.50 ▲0.25669.10 ▼18.9864.65 ▲10.52
Media Library /wp-admin/upload.php1,392 ▲44.33 ▲0.00103.06 ▼9.7343.29 ▼3.37
Category Tags /wp-admin/options-general.php?page=pct-setting-admin8002.0324.0326.63

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Almost there, just fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=pct-setting-admin
    • > Notice in wp-content/plugins/category-popular-tags/class/settings.class.php+186
    Trying to access array offset on value of type bool

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
3 plugin tags: popular, category, tags

category-popular-tags/category-popular-tag.php 85% from 13 tests

The principal PHP file in "Category Popular Tags" v. 1.0 is loaded by WordPress automatically on each request
The following require your attention:
  • Description: Please keep the plugin description shorter than 140 characters (currently 233 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("category-popular-tags.php" instead of "category-popular-tag.php")

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
Success! There were no dangerous files found in this plugin498 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP48279368
CSS1140130

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.53
Average class complexity29.00
▷ Minimum class complexity9.00
▷ Maximum class complexity49.00
Average method complexity5.67
▷ Minimum method complexity1.00
▷ Maximum method complexity49.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
PNG images were not found in this plugin