78% custom-tag-cloud

Code Review | Custom Tag Cloud

WordPress plugin Custom Tag Cloud scored78%from 54 tests.

About plugin

  • Plugin page: custom-tag-cloud
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.1.0
  • WordPress version: 6.3.1
  • First release: Jun 26, 2016
  • Latest release: Feb 14, 2019
  • Number of updates: 9
  • Update frequency: every 107.0 days
  • Top authors: thekrotek (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

400+ active /6,430 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.06MB] [CPU: ▼6.08ms] Passed 4 tests

Analyzing server-side resources used by Custom Tag Cloud
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0736.07 ▲0.23
Dashboard /wp-admin3.37 ▲0.0243.20 ▼15.69
Posts /wp-admin/edit.php3.49 ▲0.1350.42 ▲6.92
Add New Post /wp-admin/post-new.php5.95 ▲0.0683.88 ▼14.25
Media Library /wp-admin/upload.php3.29 ▲0.0636.03 ▲5.39

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Custom Tag Cloud
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲4314.40 ▲0.051.64 ▲0.0641.88 ▲2.78
Dashboard /wp-admin2,198 ▲185.57 ▼0.1091.31 ▲2.4737.99 ▼4.66
Posts /wp-admin/edit.php2,100 ▼01.96 ▼0.0240.26 ▲0.6637.12 ▲1.88
Add New Post /wp-admin/post-new.php1,534 ▲818.14 ▼5.35635.63 ▼26.0466.52 ▲14.46
Media Library /wp-admin/upload.php1,394 ▼64.22 ▲0.0295.29 ▼9.2344.70 ▲2.48

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 7 options
    • theysaidso_admin_options
    • widget_tagcloud
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/custom-tag-cloud/tagcloud.php
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/custom-tag-cloud/settings.php:15
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/custom-tag-cloud/helpers/fields.php on line 12
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/custom-tag-cloud/helpers/widget.php:12
    • > PHP Notice
      Undefined variable: fields in wp-content/plugins/custom-tag-cloud/helpers/fields.php on line 12

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: shortcode, cloud, tags, tag, tag cloud

custom-tag-cloud/tagcloud.php 85% from 13 tests

"Custom Tag Cloud" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: The principal plugin file should be the same as the plugin slug ("custom-tag-cloud.php" instead of "tagcloud.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected467 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP46037264
CSS1210141
PO File124062

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity16.50
▷ Minimum class complexity8.00
▷ Maximum class complexity25.00
Average method complexity3.50
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods13
▷ Static methods00.00%
▷ Public methods13100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

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